Hi all,
I have GitLab Community Edition 14.10.5 on premise.
I have setup 2 other VM for running shared runners on docker.
This is gitlab-runner-shared1 config
# file docker-compose.yml
version: '3'
services:
gitlab-runner-shared1:
image: 'gitlab/gitlab-runner:latest'
container_name: gitlab-runner-shared1
environment:
- REGISTER_LOCKED="false"
- TZ=Asia/Ho_Chi_Minh
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /srv/gitlab-runner-shared/config:/etc/gitlab-runner
restart: unless-stopped
# file /srv/gitlab-runner-shared/config/config.toml
concurrent = 10
check_interval = 20
[session_server]
session_timeout = 3600
[[runners]]
name = "gitlab-runner-shared1"
limit = 5
request_concurrency = 5
url = "https://gitlab.mydomain.com"
token = "xxx"
executor = "docker"
[runners.custom_build_dir]
[runners.cache]
[runners.cache.s3]
[runners.cache.gcs]
[runners.cache.azure]
[runners.docker]
memory = "16g"
cpus = "8"
tls_verify = false
image = "ruby:2.6"
privileged = true
disable_entrypoint_overwrite = false
oom_kill_disable = false
disable_cache = false
volumes = ["/var/run/docker.sock:/var/run/docker.sock", "/cache"]
shm_size = 0
pull_policy = "if-not-present"
This is gitlab-runner-shared2 config
# file docker-compose.yml
version: '3'
services:
gitlab-runner-shared2:
image: 'gitlab/gitlab-runner:latest'
container_name: gitlab-runner-shared2
environment:
- REGISTER_LOCKED="false"
- TZ=Asia/Ho_Chi_Minh
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./config:/etc/gitlab-runner
restart: unless-stopped
# file config.toml
concurrent = 10
check_interval = 20
[session_server]
session_timeout = 3600
[[runners]]
name = "gitlab-runner-shared2"
url = "https://gitlab.mydomain.com"
id = 80
limit = 5
request_concurrency = 5
token = "xxx"
token_obtained_at = 2023-10-16T03:04:26Z
token_expires_at = 0001-01-01T00:00:00Z
executor = "docker"
[runners.cache]
MaxUploadedArchiveSize = 0
[runners.docker]
tls_verify = false
image = "ruby:2.7"
memory = "10g"
cpus = "4"
privileged = true
disable_entrypoint_overwrite = false
oom_kill_disable = false
disable_cache = false
volumes = ["/cache"]
shm_size = 0
This is screen shot runner status
gitlab-runner-shared2 didn’t receive any jobs.
I want jobs are distributed evenly to 2 shared runners.
Please give me some advice, thank you very much.