Skip to content

Commit bde1888

Browse files
authored
updated lifecycle page (#901)
1 parent 79af206 commit bde1888

File tree

1 file changed

+32
-10
lines changed

1 file changed

+32
-10
lines changed

workspaces/lifecycle.md

+32-10
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,16 @@ title: "Lifecycle"
33
description: "Learn about the workspace lifecycle."
44
---
55

6-
Workspaces are designed to sustain scheduled shutdowns and rebuilds. An
7-
workspace lifecycle resilient to stops and starts means you can save dollars on
8-
cloud compute and justify more powerful dev machines :).
6+
A Coder workspace is designed to shutdown (triggered by either scheduled
7+
workspace inactivity or manually by users and administrators) and be rebuilt.
8+
9+
The persistent volume claim (or `/home/<username>`) mounted to the workspace
10+
ensures that the workspaces retain cloned code repositories and other
11+
personalization settings.
12+
13+
You can manage a Coder workspace's lifecycle at the organization-level to auto
14+
shutdown after a defined period of inactivity or when administrators want to
15+
force workspace rebuilds.
916

1017
## Rebuilds
1118

@@ -19,6 +26,13 @@ even if the underlying [image](../images/index.md) or its dependencies change.
1926
**Note:** `username` is defined in the image. See
2027
[Docker's image documentation](https://docs.docker.com/engine/reference/builder/#user)
2128

29+
## Auto-start
30+
31+
Users can configure a workspace
32+
[auto-start](https://coder.com/docs/coder/latest/workspaces/autostart) time,
33+
which sets the time when Coder will rebuild and start their workspaces. Users
34+
typically set this time to coincide with the start of their working day.
35+
2236
## Auto-off
2337

2438
Organizations can set an
@@ -38,11 +52,19 @@ available and running on an underlying host, the following steps are taken:
3852
a Git provider, your SSH key pair is injected during this step as well,
3953
allowing it to perform authenticated `git` operations.
4054

41-
1. **Execution of `/coder/configure`**: Execution of this script allows
42-
[images](../images/index.md) to perform startup operations consistent across
43-
all of the workspaces that use the image. If you need your image to include
44-
modifications to `/home`, include the instructions in this script.
55+
1. **Execution of `/coder/configure`**: Execution of this script, which is
56+
included in the workspace image, allows [images](../images/index.md) to
57+
perform startup operations that are consistent across all of the workspaces
58+
that use the image. If you need your image to include modifications to
59+
`/home/<user>`, include the instructions in this script.
60+
61+
In other words, the configure script is _not_ run as the root user but as the
62+
`/home/<user>`, so configurations are stored in `/home/<user>`. You may also
63+
run commands with `sudo`, but these changes will not persist in
64+
`/home/<user>`.
4565

46-
1. **Execution of ~/personalize`**: Execution of this script allows you to
47-
customize your personal development workspace on each rebuild. Read more on
48-
personalization [here](./personalization.md).
66+
1. **Execution of `~/personalize`**: Execution of this script allows you to
67+
customize your personal development workspace on each rebuild. Coder injects
68+
the personalize script into the workspace and includes cloning logic if a
69+
user has specified a dotfiles repo. Read more on personalization
70+
[here](./personalization.md).

0 commit comments

Comments
 (0)