Docker images with Ansible And gitlab-runner
How To Use:
$ docker run --name ansiblerunner -it -v /var/run/docker.sock:/var/run/docker.sock -v /usr/bin/docker:/usr/bin/docker -v /home/gitlab-runner/:/home/gitlab-runner/ bdpgogoup/bdpansiblerunner:v1 /bin/bash # enter docker container
1.Ansible
# Edit ansible config ,add target host configuration
$ vim /etc/ansible/hosts
[bdp-test]
10.1.2.3 # change to your server ip
# Distribution secret key
$ ssh-copy-id [email protected] #change to your server ip
#test ansible
$ ansible bdp-test -m ping
2.gitlab-runner
$ service gitlab-runner restart
$ gitlab-runner register
$ gitlab-runner start
press Ctrl + p + q detatch docker container
Content type
Image
Digest
Size
150.1 MB
Last updated
over 4 years ago
docker pull bdpgogoup/bdpansiblerunner:v2