Merge branch 'develop/gitlab-runner'

This commit is contained in:
WilliamMiceli
2019-05-28 18:51:51 -04:00
5 changed files with 170 additions and 0 deletions

View File

@@ -29,6 +29,24 @@
[https://radicale.org/] [https://radicale.org/]
[https://www.xandikos.org/] [https://www.xandikos.org/]
[https://hub.docker.com/r/libreplan/libreplan/]
[https://hub.docker.com/r/fjudith/draw.io]
[https://hub.docker.com/r/linuxserver/openvpn-as]
[https://hub.docker.com/_/drupal]
[https://hub.docker.com/_/redmine]
[https://hub.docker.com/_/node]
[https://hub.docker.com/r/zabbix/zabbix-server-mysql]
[https://hub.docker.com/r/zulip/zulip-postgresql]
[https://hub.docker.com/r/zulip/docker-zulip]
[https://hub.docker.com/r/openhab/openhab]
[https://hub.docker.com/r/devdocs/devdocs]
[https://hub.docker.com/r/bitnami/opencart]
[https://polrproject.org/]
[https://hub.docker.com/r/prestashop/prestashop]
[https://wiki.js.org/]
[https://getcockpit.com/]
[https://hub.docker.com/r/agentejo/cockpit]
[https://hub.docker.com/r/homeassistant/home-assistant]
###### GitLab Runner ###### GitLab Runner

View File

@@ -0,0 +1,5 @@
# GitLab Runner
## Technical Notes
* Using "Docker-in-Docker" type of configuration, [Described Here](https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#use-docker-in-docker-executor)

View File

@@ -0,0 +1,64 @@
version: '2'
services:
gitlab-runner-config:
image: gitlab/gitlab-runner:alpine # Alpine Linux image is designed to use only Docker as the method of spawning runners
command:
- register
- --non-interactive
- --url
- ${GITLAB_URL}
- --registration-token
- ${GITLAB_TOKEN}
- --executor
- "docker"
{{- if .Values.GITLAB_RUNNER_DESCRIPTION}}
- --description
- ${GITLAB_RUNNER_DESCRIPTION}
{{- end}}
{{- if .Values.GITLAB_TAGS}}
- --tag-list
- ${GITLAB_TAGS}
{{- end}}
- --locked=false
- --docker-image
- docker:latest
- --docker-privileged
{{- if .Values.GITLAB_IP}}
- --docker-extra-hosts
- "gitlab:${GITLAB_IP}"
{{- end}}
{{- if .Values.GITLAB_LINK}}
external_links:
- ${GITLAB_LINK}:gitlab
{{- end}}
labels:
io.rancher.container.pull_image: always
io.rancher.container.start_once: true
{{- if .Values.HOST_LABEL}}
io.rancher.scheduler.affinity:host_label: ${HOST_LABEL}
{{- end}}
traefik.enable: false
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /Rancher/${DATA_DIR}:/etc/gitlab-runner
gitlab-runner:
image: gitlab/gitlab-runner:alpine # Alpine Linux image is designed to use only Docker as the method of spawning runners
command:
- run
{{- if .Values.GITLAB_LINK}}
external_links:
- ${GITLAB_LINK}:gitlab
{{- end}}
labels:
io.rancher.container.pull_image: always
{{- if .Values.HOST_LABEL}}
io.rancher.scheduler.affinity:host_label: ${HOST_LABEL}
{{- end}}
io.rancher.sidekicks: gitlab-runner-config
traefik.enable: false
privileged: true
restart: always
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /Rancher/${DATA_DIR}:/etc/gitlab-runner

View File

@@ -0,0 +1,75 @@
version: '2'
catalog:
name: GitLab Runner
version: latest
# description:
# minimum_rancher_version:
# maximum_rancher_version:
# upgrade_from:
# uuid:
questions:
- variable: "HOST_LABEL"
label: "Host Label Key/Value Pair"
description: |
(Optional) The Key/Value pair of the host which the stack should be deployed.
default: "host.id=Host2"
required: false
type: string
- variable: "GITLAB_URL"
label: "GitLab URL"
description: |
The URL which your GitLab instance can be reached at.
You can use the service selection and alias to create a direct link if it is in your Rancher environment.
default: "http://gitlab/"
required: true
type: string
- variable: "GITLAB_TOKEN"
label: "GitLab Registration Token"
description: |
The registration token provided by the GitLab instance.
# default:
required: true
type: string
- variable: "GITLAB_RUNNER_DESCRIPTION"
label: "GitLab Runner Description"
description: |
(Optional) A description for the GitLab Runner.
# default:
required: false
type: string
- variable: "GITLAB_TAGS"
label: "GitLab Runner Tags"
description: |
(Optional) Tags for the GitLab Runner, separated by a comma.
These can be changed later in GitLab.
default: "docker"
required: false
type: string
- variable: "GITLAB_LINK"
label: "GitLab Service"
description: |
(Optional) Create a direct link to the GitLab service.
required: false
type: service
- variable: "GITLAB_IP"
label: "Local GitLab IP"
description: |
(Optional) The local IP address of the GitLab service.
# default: ""
required: false
type: string
- variable: "DATA_DIR"
label: "Data Directory"
description: |
The directory to store persistent data for the stack.
default: "Personal/GitLab-Runner"
required: true
type: string

View File

@@ -0,0 +1,8 @@
name: GitLab Runner
description: |
STATUS: Experimental
version: latest
# category:
maintainer: WilliamMiceli
# license:
# projectURL: