Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
G
gitlab-runner
Manage
Activity
Members
Labels
Plan
Issues
2
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ansible
gitlab-runner
Commits
2f789b07
Commit
2f789b07
authored
7 years ago
by
Mark
Browse files
Options
Downloads
Patches
Plain Diff
Remove ssh variable requirement, set docker-volumes correctly for 10.x, add locked variable
parent
40fd0033
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
defaults/main.yml
+12
-1
12 additions, 1 deletion
defaults/main.yml
handlers/main.yml
+1
-0
1 addition, 0 deletions
handlers/main.yml
tasks/main.yml
+4
-4
4 additions, 4 deletions
tasks/main.yml
tasks/register-runner.yml
+10
-7
10 additions, 7 deletions
tasks/register-runner.yml
with
27 additions
and
12 deletions
defaults/main.yml
+
12
−
1
View file @
2f789b07
...
...
@@ -19,4 +19,15 @@ gitlab_runner_docker_image: ''
gitlab_runner_tags
:
[]
# Docker privileged mode
gitlab_runner_docker_privileged
:
false
# Runner SSH user
gitlab_runner_ssh_user
:
'
'
# Runner SSH host
gitlab_runner_ssh_host
:
'
'
# Runner SSH port
gitlab_runner_ssh_port
:
'
'
# Runner SSH password
gitlab_runner_ssh_password
:
'
'
# Runner SSH identity file
gitlab_runner_ssh_identity_file
:
'
'
# Runner Locked
gitlab_runner_locked
:
'
false'
\ No newline at end of file
This diff is collapsed.
Click to expand it.
handlers/main.yml
+
1
−
0
View file @
2f789b07
---
-
name
:
restart_gitlab_runner
service
:
name=gitlab-runner state=restarted
become
:
yes
This diff is collapsed.
Click to expand it.
tasks/main.yml
+
4
−
4
View file @
2f789b07
---
-
name
:
Install GitLab Runner (Debian)
i
nclude
:
install-debian.yml
i
mport_tasks
:
install-debian.yml
when
:
ansible_os_family == 'Debian'
-
name
:
Install GitLab Runner (RedHat)
i
nclude
:
install-redhat.yml
i
mport_tasks
:
install-redhat.yml
when
:
ansible_os_family == 'RedHat'
-
name
:
Set global options
i
nclude
:
global-setup.yml
i
mport_tasks
:
global-setup.yml
-
name
:
Register GitLab Runner
i
nclude
:
register-runner.yml
i
mport_tasks
:
register-runner.yml
when
:
gitlab_runner_registration_token != ''
This diff is collapsed.
Click to expand it.
tasks/register-runner.yml
+
10
−
7
View file @
2f789b07
...
...
@@ -12,11 +12,14 @@
--description '{{ gitlab_runner_description }}'
--tag-list '{{ gitlab_runner_tags | join(",") }}'
--executor '{{ gitlab_runner_executor }}'
--locked='{{gitlab_runner_locked}}'
--docker-image '{{ gitlab_runner_docker_image }}'
--docker-volumes [ "{{ gitlab_runner_docker_volumes | join('", "') }}" ]
--ssh-user '{{gitlab_runner_ssh_user}}'
--ssh-host '{{gitlab_runner_ssh_host}}'
--ssh-port '{{gitlab_runner_ssh_port}}'
--ssh-password '{{gitlab_runner_ssh_password}}'
--ssh-identity-file '{{gitlab_runner_ssh_identity_file}}'
when
:
configured_runners.stderr.find('\n{{ gitlab_runner_description }}') == -1
{% if gitlab_runner_docker_volumes is defined %}
--docker-volumes "{{ gitlab_runner_docker_volumes | join('" "') }}"
{% endif %}
--ssh-user '{{ gitlab_runner_ssh_user }}'
--ssh-host '{{ gitlab_runner_ssh_host }}'
--ssh-port '{{ gitlab_runner_ssh_port }}'
--ssh-password '{{ gitlab_runner_ssh_password }}'
--ssh-identity-file '{{ gitlab_runner_ssh_identity_file }}'
when
:
configured_runners.stderr.find('\n' + gitlab_runner_description) == -1
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment