diff --git a/runhouse/resources/hardware/cluster_factory.py b/runhouse/resources/hardware/cluster_factory.py index 520a3d76e..b719a74a0 100644 --- a/runhouse/resources/hardware/cluster_factory.py +++ b/runhouse/resources/hardware/cluster_factory.py @@ -123,6 +123,10 @@ def cluster( # If the the user changed the image and wants to restart the server to apply the new # changes, we need to update the image in the cluster object c.image = image or c.image + if kwargs.get("autostop_mins"): + c.autostop_mins = kwargs.get("autostop_mins") + if launcher: + c.launcher = launcher if den_auth: c.save() return c @@ -443,6 +447,8 @@ def ondemand_cluster( # If the the user changed the image and wants to restart the server to apply the new # changes, we need to update the image in the cluster object c.image = image or c.image + c.autostop_mins = autostop_mins or c.autostop_mins + c.launcher = launcher or c.launcher if den_auth: c.save() return c