Add gitlab-ci-multi-runner

This commit is contained in:
Frederic Leger 2017-05-23 00:13:49 +02:00
parent adc11b89ae
commit cb30dc45a9
4 changed files with 79 additions and 0 deletions

View File

@ -0,0 +1,44 @@
version: '2'
services:
gitlab-runner-config:
image: gitlab/gitlab-runner:alpine
stdin_open: true
volumes:
- /etc/gitlab-runner/
tty: true
command:
- register
- -n
- --url
- ${GITLAB_URL}
- --registration-token
- ${GITLAB_TOKEN}
- --executor
- docker
- --description
- Rancher Docker Runner
- --docker-image
- docker:latest
- --docker-volumes
- /var/run/docker.sock:/var/run/docker.sock
- --docker-privileged
labels:
io.rancher.container.pull_image: always
io.rancher.container.start_once: 'true'
gitlab-runner:
image: gitlab/gitlab-runner:alpine
stdin_open: true
volumes:
- /var/run/docker.sock:/var/run/docker.sock
tty: true
volumes_from:
- gitlab-runner-config
command:
- run
labels:
io.rancher.sidekicks: gitlab-runner-config
io.rancher.container.pull_image: always
io.rancher.scheduler.global: 'true'

View File

@ -0,0 +1,30 @@
version: '2'
catalog:
name: "gitlab-multi-runner"
version: "0.1"
description: "a Gitlab pipelines multi-runner, that will spawn privates runners in your infra."
# minimum_rancher_version:
# maximum_rancher_version:
# upgrade_from: # The previous versions that this template can be upgraded from
questions:
- variable: "GITLAB_URL"
label: "Gitlab Url"
description: "Url to your Gitlab CI endpoint"
type: "string"
default: "https://gitlab.com/ci"
required: true
- variable: "GITLAB_TOKEN"
label: "Gitlab Token"
description: "Token provided in you project settings"
type: "string"
default: "xxxxxxxxxxxxxxxxxxxx"
required: true
services:
gitlab-runner-config:
scale: 1
start_on_create: true
gitlab-runner:
start_on_create: true

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

View File

@ -0,0 +1,5 @@
name: gitlab-multi-runner
description: |
a Gitlab pipelines multi-runner, that will spawn privates runners in your infra.
version: 1
category: Continuous Integration