Skip to content
Snippets Groups Projects
Commit 3d019a51 authored by void's avatar void
Browse files

gitlab runner auf webserver

parent 3b2cbc53
No related branches found
No related tags found
No related merge requests found
...@@ -79,6 +79,8 @@ alert: ...@@ -79,6 +79,8 @@ alert:
- { name: "dokuwiki_app_1" } - { name: "dokuwiki_app_1" }
- { name: "coturn_coturn_1" } - { name: "coturn_coturn_1" }
- { name: "gitlab_app_1" } - { name: "gitlab_app_1" }
- { name: "gitlab_dind_1" }
- { name: "gitlab_runner_1" }
- { name: "hackmd_app_1" } - { name: "hackmd_app_1" }
- { name: "hackmd_db_1" } - { name: "hackmd_db_1" }
- { name: "icinga_app_1" } - { name: "icinga_app_1" }
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
with_items: with_items:
- { path: /srv/shared/noreply_email_pass, length: -1 } - { path: /srv/shared/noreply_email_pass, length: -1 }
- { path: /srv/ldap/secret/ldap_readonly_pass, length: -1 } - { path: /srv/ldap/secret/ldap_readonly_pass, length: -1 }
- { path: /srv/gitlab/runner_registration_token, length: -1 }
# Benötigte Verzeichnisstrukturen erstellen # Benötigte Verzeichnisstrukturen erstellen
...@@ -18,6 +19,7 @@ ...@@ -18,6 +19,7 @@
- "/srv/gitlab/conf/" - "/srv/gitlab/conf/"
- "/srv/gitlab/data/" - "/srv/gitlab/data/"
- "/srv/gitlab/log" - "/srv/gitlab/log"
- "/srv/gitlab/runner"
# Konfigurationsdateien erstellen # Konfigurationsdateien erstellen
......
...@@ -29,6 +29,65 @@ services: ...@@ -29,6 +29,65 @@ services:
- default - default
- web - web
# Docker in Docker for Gitlab-Runner execution
# see https://forum.gitlab.com/t/example-gitlab-runner-docker-compose-configuration/67344
dind:
image: docker:20-dind
restart: always
privileged: true
environment:
DOCKER_TLS_CERTDIR: ""
command:
- --storage-driver=overlay2
networks:
- default
runner:
restart: always
image: registry.gitlab.com/gitlab-org/gitlab-runner:alpine
depends_on:
- dind
- app
environment:
- DOCKER_HOST=tcp://dind:2375
volumes:
- "/srv/gitlab/runner:/etc/gitlab-runner:z"
networks:
- default
# Runner Registration
# Excecute once when Gitlab is running
# register-runner:
# restart: 'no'
# image: registry.gitlab.com/gitlab-org/gitlab-runner:alpine
# depends_on:
# - dind
# - app
# environment:
# - CI_SERVER_URL=https://{{ domain }}
# - REGISTRATION_TOKEN={{ runner_registration_token }}
# command:
# - register
# - --non-interactive
# - --locked=false
# - --name=warpzone-webserver
# - --executor=docker
# - --docker-image=docker:20-dind
# - --docker-volumes=/var/run/docker.sock:/var/run/docker.sock
# volumes:
# - "/srv/gitlab/runner:/etc/gitlab-runner:z"
# networks:
# - default
networks: networks:
web: web:
external: true external: true
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment