Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fgribreau/docker-jenkins-slave
:muscle: Run a Jenkins slave in docker AND access to docker cli from jobs
https://github.com/fgribreau/docker-jenkins-slave
docker jenkins jenkins-slave
Last synced: 9 days ago
JSON representation
:muscle: Run a Jenkins slave in docker AND access to docker cli from jobs
- Host: GitHub
- URL: https://github.com/fgribreau/docker-jenkins-slave
- Owner: FGRibreau
- Created: 2016-05-29T10:56:00.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-12-28T22:28:44.000Z (almost 7 years ago)
- Last Synced: 2024-11-21T04:34:34.280Z (about 1 month ago)
- Topics: docker, jenkins, jenkins-slave
- Homepage: http://blog.fgribreau.com/2016/05/how-to-start-jenkins-slave-inside.html
- Size: 2.93 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Docker Jenkins Slave
====================> Run a Jenkins slave in docker AND access to docker cli from jobs
- Go to Jenkins > manage > node management
- Click *Create a node*
- Check *Permanent Agent*
- Set *working directory* to something like `/data/jenkins-slave` (if you specify something else, don't forget to also change the command below)
- Save
- Download slave-agent.jnlp, open it to retrieve your secret
- Change the command below with the working directory you specified, your slave-agent URL and jenkins secret
- Run it
- Enjoy :+1:```
docker run --rm -v /data/jenkins-slave:/data/jenkins-slave -v /var/run/docker.sock:/var/run/docker.sock --rm fgribreau/jenkins-slave:latest java -jar /app/agent.jar -jnlpUrl "http://YOUR_OWN_JENKINS.com/computer/SLAVE_NAME/slave-agent.jnlp" -secret "JENKINS_SECRET"
```Wonder why this is awesome? Check out [the related blog post](http://blog.fgribreau.com/2016/05/how-to-start-jenkins-slave-inside.html).
### Simply want to run Jenkins slave from a docker container?
Check out [How to start a Jenkins slave inside Docker](http://blog.fgribreau.com/2016/05/how-to-start-jenkins-slave-in-docker.html) on my blog, (spoiler: it only requires docker official java image).