You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/modules/execution-runner/pages/machine-runner-3-configuration-reference.adoc
+58-15Lines changed: 58 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,30 +24,37 @@ logging:
24
24
25
25
NOTE: Machine runner can also be configured via environment variables. These will be prioritized over the YAML file, if set.
26
26
27
+
---
28
+
27
29
[#api-auth-token]
28
-
=== `api.auth_token`
30
+
=== api.auth_token
29
31
30
32
`$CIRCLECI_RUNNER_API_AUTH_TOKEN`
31
33
32
34
The token is used to identify the machine runner to CircleCI and can be generated by the xref:toolkit:local-cli.adoc[CircleCI CLI]. An existing token may be shared among many installations, but this token only allows a particular `resource_class` to be specified.
33
35
36
+
---
37
+
34
38
[#api-url]
35
-
=== `api.url`
39
+
=== api.url
36
40
37
41
`$CIRCLECI_RUNNER_API_URL`
38
42
39
43
The URL will be pointing to `https://runner.circleci.com` by default. It should not be modified unless you have a CircleCI server installation. In that case, it must be set to the URL of your server installation.
40
44
45
+
---
46
+
41
47
[#runner-name]
42
-
=== `runner.name`
48
+
=== runner.name
43
49
44
50
`$CIRCLECI_RUNNER_NAME`
45
51
46
52
`RUNNER_NAME` is a unique name of your choosing assigned to this particular machine runner. CircleCI recommends using the hostname of the machine so that it can be used to identify the agent when viewing statuses and job results in the CircleCI web app. The only special characters accepted in `RUNNER_NAME` are `. () - _`.
This flag enables you to control the working directory cleanup after each job.
@@ -189,8 +204,10 @@ runner:
189
204
cleanup_working_directory: true
190
205
```
191
206
207
+
---
208
+
192
209
[#runner-use-ssh-dir-for-checkout-keys]
193
-
=== `runner.use_home_ssh_dir_for_checkout_keys`
210
+
=== runner.use_home_ssh_dir_for_checkout_keys
194
211
`$USE_HOME_SSH_DIR_FOR_CHECKOUT_KEYS`
195
212
196
213
This flag enables you to use the home directory of the user running the self-hosted runner instance for storing SSH checkout keys.
@@ -209,8 +226,10 @@ runner:
209
226
use_home_ssh_dir_for_checkout_keys: true
210
227
```
211
228
229
+
---
230
+
212
231
[#runner-mode]
213
-
=== `runner.mode`
232
+
=== runner.mode
214
233
215
234
`$CIRCLECI_RUNNER_MODE`
216
235
@@ -249,8 +268,26 @@ runner:
249
268
mode: single-task
250
269
```
251
270
271
+
---
272
+
273
+
[#cache-task-agent]
274
+
=== runner.cache_task_agent
275
+
276
+
`$CIRCLECI_RUNNER_CACHE_TASK_AGENT`
277
+
278
+
When set to true, machine runner will not clear the task-agent cache when the agent shuts down. On startup the machine agent will check for an already downloaded task agent and will use that task-agent unless there is a newer version of task-agent available for download. This feature is off by default. This may be particularly useful for Windows which relies on `single-task` mode.
279
+
280
+
Example:
281
+
282
+
```yaml
283
+
runner:
284
+
cache_task_agent: true
285
+
```
286
+
287
+
---
288
+
252
289
[#runner-max-run-time]
253
-
=== `runner.max_run_time`
290
+
=== runner.max_run_time
254
291
255
292
`$CIRCLECI_RUNNER_MAX_RUN_TIME`
256
293
@@ -285,8 +322,10 @@ Draining can end in one of two ways:
285
322
* The task has been in the draining state for longer than the configured `max_run_time`
286
323
* An additional TERM signal is received by the machine runner during _draining_
287
324
325
+
---
326
+
288
327
[#runner-idle-timeout]
289
-
=== `runner.idle_timeout`
328
+
=== runner.idle_timeout
290
329
`$CIRCLECI_RUNNER_IDLE_TIMEOUT`
291
330
292
331
This timeout will enable a machine runner to terminate if no task has been claimed within the given time period. The value is a string with the following unit identifiers: `h`, `m` or `s` for hours, minutes, and seconds respectively (for example, `5m` is 5 minutes).
@@ -300,8 +339,10 @@ runner:
300
339
idle_timeout: 1h
301
340
```
302
341
342
+
---
343
+
303
344
[#runner-ssh-advertise-addr]
304
-
=== `runner.ssh.advertise_addr`
345
+
=== runner.ssh.advertise_addr
305
346
`$CIRCLECI_RUNNER_SSH_ADVERTISE_ADDR`
306
347
307
348
This parameter enables the “Rerun job with SSH” feature. Before enabling this feature, there are <<#considerations-before-enabling-ssh-debugging,*important considerations*>> that should be made. Rerun with SSH is not currently available on container runner.
@@ -328,6 +369,8 @@ Task-agent runs an embedded SSH server and agent on a dedicated port when the
328
369
* The SSH server is configured for public key authentication. Anyone with permission to initiate a job can rerun it with SSH. However, only the user who initiated the rerun will have their SSH public keys added to the server for the duration of the SSH session.
329
370
* Rerunning a job with SSH will hold the job open for *two hours* if a connection is made to the SSH server, or *ten minutes* if no connection is made, unless cancelled. While in this state, the job is counted against an organization’s concurrency limit, and the task-agent will be unavailable to handle other jobs. Therefore, it is recommended to cancel an SSH rerun job explicitly (through the web UI or CLI) when finished debugging.
0 commit comments