Skip to content

Commit 58fcb5f

Browse files
committed
update docker-compose example
1 parent c920c05 commit 58fcb5f

1 file changed

Lines changed: 17 additions & 7 deletions

File tree

docker-compose.yml

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,27 @@ version: "3"
22
services:
33
worker:
44
image: ghcr.io/onmcu/dockerized-gha-runner:latest
5+
restart: always
6+
stop_grace_period: 30s
57
environment:
68
RUNNER_SCOPE: org
7-
RUNNER_ORG: {{ GITHUB_RUNNER_ORG }}
8-
RUNNER_NAME: {{ GITHUB_RUNNER_NAME }}
9-
RUNNER_TOKEN: {{ GITHUB_RUNNER_TOKEN }}
10-
RUNNER_WORKDIR: /tmp/runner/work
9+
RUNNER_NAME_PREFIX: selfhosted-runner
10+
ORG_NAME: {{ GITHUB_RUNNER_ORG }}
11+
ACCESS_TOKEN: {{ GITHUB_RUNNER_TOKEN }}
12+
RUNNER_WORKDIR: /tmp/github-runner
1113
CONFIGURED_ACTIONS_RUNNER_FILES_DIR: /runner/data
1214
LABELS: linux,x64,gpu,rust
1315
DISABLE_AUTOMATIC_DEREGISTRATION: true
14-
volumes:
15-
- "./data:/runner/data:Z"
16-
- "./tmp:/tmp/runner:Z"
16+
DISABLE_AUTO_UPDATE: true
17+
RUN_AS_ROOT: false
18+
EPHEMERAL: "true"
1719
security_opt:
1820
- label=disable
21+
# For rootless podman:
22+
# Create these folders and set `chmod o+w` for them and see which UID/GID creates the profiles:
23+
# Then `chmod o-w` again and `chown` by that UID/GID
24+
volumes:
25+
- ./config:/config
26+
- ./tmp:/tmp/github-runner
27+
- ./cache-cargo-registry:/home/runner/.cargo/registry
28+
- ./cache-cargo-git:/home/runner/.cargo/git

0 commit comments

Comments
 (0)