Updated jenkins file

This commit is contained in:
Ådne E. Moldesæter 2020-08-27 22:38:36 +02:00
parent aec0c72f9c
commit 83f9d30c20

13
Jenkinsfile vendored
View File

@ -1,8 +1,21 @@
pipeline { pipeline {
agent any agent any
stages { stages {
stage('build') {
agent {
docker {
image 'rust'
reuseNode true
}
}
steps {
sh 'cargo build --release'
stash includes: 'target/release/rollux', name: 'app'
}
}
stage('docker build') { stage('docker build') {
steps { steps {
unstash 'app'
echo 'Starting docker image build' echo 'Starting docker image build'
script { script {
docker.withRegistry("https://pkg.northcode.no", 'docker-login') { docker.withRegistry("https://pkg.northcode.no", 'docker-login') {