I'm trying to instantiate a VM with a maximum run duration as described here.
from google.cloud import compute_v1
...
instance = compute_v1.Instance()
instance.scheduling = compute_v1.Scheduling()
instance.scheduling.instant_termination_action = "DELETE"
instance.scheduling.max_run_duration = '60s'
This code throws an AttributeError: Unknown field for Scheduling: max_run_duration
I'm assuming that since the maxRunDuration field is in preview only, the Python client doesn't recognize it.
Is there any other way to set the maximum run duration using the Python client?