Created
February 23, 2016 08:35
-
-
Save iocanel/f68f0f1971ef8a610fa7 to your computer and use it in GitHub Desktop.
Pushing a single image to multiple registries
This file contains 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
node { | |
//Using the DSL syntax | |
kubernetes.image().withName("example").build().fromPath(".") | |
kubernetes.image().withName("example").tag().inRepository('default/example').withTag("1.0") | |
kubernetes.image().withName("default/example").push().withTag("1.0").toRegistry("172.30.101.121:5000") | |
kubernetes.image().withName("default/example").push().withTag("1.0").toRegistry("172.30.101.122:5000") | |
kubernetes.image().withName("default/example").push().withTag("1.0").toRegistry("172.30.101.123:5000") | |
} | |
node { | |
//Using the functions with named parameters | |
buildImage(name: 'example', path: '.') | |
tagImage(name: 'example', repo: 'default/example', tag: '1.0') | |
pushImage(name: 'default/example', tag: '1.0', registry: '172.30.101.121:5000') | |
pushImage(name: 'default/example', tag: '1.0', registry: '172.30.101.122:5000') | |
pushImage(name: 'default/example', tag: '1.0', registry: '172.30.101.123:5000') | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment