Skip to content
Snippets Groups Projects
Commit ca06d723 authored by Rafael László's avatar Rafael László :speech_balloon:
Browse files

Update runner playbook

parent 2b6d7434
No related branches found
No related tags found
No related merge requests found
......@@ -14,3 +14,7 @@ Update the variables in `vars` folder.
`sudo -s`
`cd /home/ubuntu`
`podman-compose up -d`
Register the runner with registration token and then
update the config using `/home/ubuntu/gitlab-runner/config.toml.example` file.
......@@ -22,5 +22,11 @@
dest: /etc/ssh/sshd_config
mode: 0600
- name: Ensure sshd is restarted and enabled to start at boot.
service:
name: sshd
state: restarted
enabled: yes
- name: Setup Runner
include_tasks: runner.yaml
---
- name: Ensure sshd is restarted and enabled to start at boot.
service:
name: sshd
state: restarted
enabled: yes
- name: Install podman compose
pip:
name:
......@@ -20,12 +14,12 @@
- name: Copy config toml
template:
src: home/ubuntu/gitlab-runner/config.toml.j2
dest: /home/ubuntu/gitlab-runner/config.toml
src: home/ubuntu/gitlab-runner/config.toml.example.j2
dest: /home/ubuntu/gitlab-runner/config.toml.example
owner: ubuntu
group: ubuntu
mode: 0700
backup: true
backup: false
become: true
- name: Copy compose file
......
......@@ -6,9 +6,9 @@ check_interval = 1
session_timeout = 1800
[[runners]]
name = {{ runner.name}}
url = {{ runner.url }}
token = {{ runner.token }}
name = "{{ runner.name }}"
url = "{{ runner.url }}"
token = "some token"
executor = "docker"
[runners.custom_build_dir]
{% if runner.s3cache is defined %}
......@@ -17,11 +17,11 @@ check_interval = 1
Path = "runner"
Shared = true
[runners.cache.s3]
ServerAddress = {{ runner.s3cache.server_address }}
BucketName = {{ runner.s3cache.bucket_name }}
ServerAddress = "{{ runner.s3cache.server_address }}"
BucketName = "{{ runner.s3cache.bucket_name }}"
Insecure = false
AccessKey = {{ runner.s3cache.access_key }}
SecretKey = {{ runner.s3cache.secret_key }}
AccessKey = "{{ runner.s3cache.access_key }}"
SecretKey = "{{ runner.s3cache.secret_key }}"
{% endif %}
[runners.docker]
tls_verify = false
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment