-
-
Save mindw/5239295c6db1950b32a7b5d7bf02ca7e to your computer and use it in GitHub Desktop.
Jenkins kubernetes dind
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| podTemplate(label: 'mypod', containers: [ | |
| containerTemplate(name: 'docker', image: 'docker:dind', ttyEnabled: true, alwaysPullImage: true, privileged: true, | |
| command: 'dockerd --host=unix:///var/run/docker.sock --host=tcp://0.0.0.0:2375 --storage-driver=overlay') | |
| ], | |
| volumes: [emptyDirVolume(memory: false, mountPath: '/var/lib/docker')]) { | |
| node ('mypod') { | |
| stage 'Run a docker thing' | |
| container('docker') { | |
| stage 'Docker thing1' | |
| sh 'docker pull redis' | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment