File tree 1 file changed +23
-1
lines changed
1 file changed +23
-1
lines changed Original file line number Diff line number Diff line change @@ -162,6 +162,28 @@ resource "docker_container" "workspace" {
162
162
}
163
163
```
164
164
165
+ #### Using updated images when rebuilding a workspace
166
+
167
+ To ensure that Coder uses an updated image when rebuilding a workspace, we
168
+ suggest that admins update the tag in the template (e.g., ` my-image:v0.4.2 ` ->
169
+ ` my-image:v0.4.3 ` ) or digest (` my-image@sha256:[digest] ` ->
170
+ ` my-image@sha256:[new_digest] ` ).
171
+
172
+ Alternatively, if you're willing to wait for longer start times from Coder, you
173
+ can set the ` imagePullPolicy ` to ` Always ` in your Terraform template; when set,
174
+ Coder will check ` image:tag ` on every build and update if necessary:
175
+
176
+ ``` tf
177
+ resource "kubernetes_pod" "podName" {
178
+ spec {
179
+ container {
180
+ image_pull_policy = "Always"
181
+ }
182
+ }
183
+ }
184
+ ```
185
+
186
+
165
187
#### Delete workspaces
166
188
167
189
When a workspace is deleted, the Coder server essentially runs a
@@ -172,7 +194,7 @@ resources associated with the workspace.
172
194
> [ prevent-destroy] ( https://www.terraform.io/language/meta-arguments/lifecycle#prevent_destroy )
173
195
> and
174
196
> [ ignore-changes] ( https://www.terraform.io/language/meta-arguments/lifecycle#ignore_changes )
175
- > meta-arguments can be used to accidental data loss.
197
+ > meta-arguments can be used to accidental data loss.
176
198
177
199
### Coder apps
178
200
You can’t perform that action at this time.
0 commit comments