This article has been archived. Please see Coder Docs for the updated version.
You can specify the duration of inactivity allowed before an environment automatically shuts down. This helps you optimize your resource allocation since automatically shutting down idle environments can save on resource availability and reduce costs.
An environment that's been stopped must be rebuilt before it can be used again. All data outside of /home is lost during rebuild. Please store any changes that you would like persisted across rebuilds with the Personalize feature.
Configuring Environment Shutdown Behavior
Configuring the environment shutdown behavior is done at the organization level.
In the Coder dashboard, go to Manage > Organizations and choose the organization you'd like to modify.
Click Edit in the top-right. In the dialog that opens, use the slider underneath Environment Shutdown Behavior to select the maximum allowed duration.
If you set the slider to Never, no environments will shut down automatically.