4520 shaares
2 résultats
taggé
runner
Voici le script Ansible :
- name: List configured runners
command: gitlab-runner list
register: configured_runners
changed_when: False
- name: Register runner to GitLab
command: gitlab-runner register >
--non-interactive
--url '{{ gitlab_runner_coordinator_url }}'
--registration-token '{{ gitlab_runner_registration_token }}'
--description '{{ gitlab_runner_description }}'
--tag-list '{{ gitlab_runner_tags | join(",") }}'
--executor '{{ gitlab_runner_executor }}'
--docker-image '{{ gitlab_runner_docker_image }}'
when: configured_runners.stderr.find('\n{{ gitlab_runner_description }}') == -1
Hors Ansible :
gitlab-runner register \
--non-interactive \
--url 'https ://${GITLAB_HOST}:${GITLAB_PORT}/ci' \
--registration-token 'Yy1YWzcDVyBbc9RNGxsb' \
--description 'Mon GitLab Runner' \
--tag-list 'java php nodejs' \
--executor 'shell'
# --docker-image '{{ gitlab_runner_docker_image }}'