First test configuration of GitLab Runner
This commit is contained in:
1
templates/GitLab-Runner/0/README.md
Normal file
1
templates/GitLab-Runner/0/README.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
# GitLab Runner
|
||||||
43
templates/GitLab-Runner/0/docker-compose.yml
Normal file
43
templates/GitLab-Runner/0/docker-compose.yml
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
version: '2'
|
||||||
|
|
||||||
|
services:
|
||||||
|
gitlab-runner:
|
||||||
|
image: gitlab/gitlab-runner:alpine
|
||||||
|
command:
|
||||||
|
- register
|
||||||
|
- --non-interactive
|
||||||
|
- --url
|
||||||
|
- ${GITLAB_URL}
|
||||||
|
- --registration-token
|
||||||
|
- ${GITLAB_TOKEN}
|
||||||
|
- --executor
|
||||||
|
- "docker"
|
||||||
|
- --docker-image
|
||||||
|
- alpine:latest
|
||||||
|
{{- if .Values.GITLAB_RUNNER_DESCRIPTION}}
|
||||||
|
- --description
|
||||||
|
- ${GITLAB_RUNNER_DESCRIPTION}
|
||||||
|
{{- end}}
|
||||||
|
{{- if .Values.GITLAB_TAGS}}
|
||||||
|
- --tag-list
|
||||||
|
- ${GITLAB_TAGS}
|
||||||
|
{{- end}}
|
||||||
|
- --run-untagged
|
||||||
|
- --locked="false"
|
||||||
|
dns:
|
||||||
|
- 1.1.1.1
|
||||||
|
- 1.0.0.1
|
||||||
|
environment:
|
||||||
|
{{- if .Values.GITLAB_LINK}}
|
||||||
|
external_links:
|
||||||
|
- ${GITLAB_LINK}{{- if .Values.GITLAB_LINK_ALIAS}}:${GITLAB_LINK_ALIAS}{{- end}}
|
||||||
|
{{- end}}
|
||||||
|
labels:
|
||||||
|
io.rancher.container.pull_image: always
|
||||||
|
{{- if .Values.HOST_LABEL}}
|
||||||
|
io.rancher.scheduler.affinity:host_label: ${HOST_LABEL}
|
||||||
|
{{- end}}
|
||||||
|
traefik.enable: false
|
||||||
|
restart: on-failure
|
||||||
|
volumes:
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
67
templates/GitLab-Runner/0/rancher-compose.yml
Normal file
67
templates/GitLab-Runner/0/rancher-compose.yml
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
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_LINK_ALIAS"
|
||||||
|
label: "GitLab Service Alias"
|
||||||
|
description: |
|
||||||
|
(Optional) Create an alias for the service.
|
||||||
|
default: "gitlab"
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
8
templates/GitLab-Runner/config.yml
Normal file
8
templates/GitLab-Runner/config.yml
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
name: GitLab Runner
|
||||||
|
description: |
|
||||||
|
STATUS: Experimental
|
||||||
|
version: latest
|
||||||
|
# category:
|
||||||
|
maintainer: WilliamMiceli
|
||||||
|
# license:
|
||||||
|
# projectURL:
|
||||||
Reference in New Issue
Block a user