@@ -148,9 +148,19 @@ coder templates push on-prem-chicago \
148
148
--provisioner-tag datacenter=chicago
149
149
```
150
150
151
+ This can also be done in the UI when building a template:
152
+
153
+ > ![ template tags] ( ../images/admin/provisioner-tags.png )
154
+
151
155
Alternatively, a template can target a provisioner via
152
156
[ workspace tags] ( https://github.com/coder/coder/tree/main/examples/workspace-tags )
153
- inside the Terraform.
157
+ inside the Terraform. See the
158
+ [ workspace tags documentation] ( ../admin/templates/extending-templates/workspace-tags.md )
159
+ for more information.
160
+
161
+ > [ !NOTE] Workspace tags defined with the ` coder_workspace_tags ` data source
162
+ > template ** do not** automatically apply to the template import job! You may
163
+ > need to specify the desired tags when importing the template.
154
164
155
165
A provisioner can run a given build job if one of the below is true:
156
166
@@ -170,6 +180,14 @@ However, it will not pick up any build jobs that do not have either of the
170
180
` environment ` or ` datacenter ` tags set. It will also not pick up any build jobs
171
181
from templates with the tag ` scope=user ` set.
172
182
183
+ > [ !NOTE] If you only run tagged provisioners, you will need to specify a set of
184
+ > tags that matches at least one provisioner for _ all_ template import jobs and
185
+ > workspace build jobs.
186
+ >
187
+ > You may wish to run at least one additional provisioner with no additional
188
+ > tags so that provisioner jobs with no additional tags defined will be picked
189
+ > up instead of potentially remaining in the Pending state indefinitely.
190
+
173
191
This is illustrated in the below table:
174
192
175
193
| Provisioner Tags | Job Tags | Can Run Job? |
0 commit comments