Skip to content
Snippets Groups Projects
Commit 0c9c23ac authored by OZGCloud's avatar OZGCloud
Browse files

seperate build and nativ image

parent 9e9dd1d3
No related branches found
No related tags found
No related merge requests found
...@@ -46,8 +46,20 @@ pipeline { ...@@ -46,8 +46,20 @@ pipeline {
} }
container("quarkus-22"){ container("quarkus-22"){
configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) {
//sh 'mvn -s $MAVEN_SETTINGS clean install -Dmaven.wagon.http.retryHandler.count=3' sh './mvnw -s $MAVEN_SETTINGS clean deploy -Dmaven.wagon.http.retryHandler.count=3'
sh './mvnw -s $MAVEN_SETTINGS package -Pnative -Dquarkus.native.container-build=true' }
}
}
}
stage('Build native image') {
steps {
script {
FAILED_STAGE=env.STAGE_NAME
}
container("quarkus-22"){
configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) {
sh './mvnw -s $MAVEN_SETTINGS -Pnative -Dquarkus.native.container-build=true -Dmaven.wagon.http.retryHandler.count=3'
} }
} }
} }
...@@ -72,26 +84,6 @@ pipeline { ...@@ -72,26 +84,6 @@ pipeline {
// } // }
// } // }
stage('Build image') {
steps {
script {
FAILED_STAGE=env.STAGE_NAME
container("docker") {
withCredentials([usernamePassword(credentialsId: 'jenkins-docker-login', usernameVariable: 'USER', passwordVariable: 'PASSWORD')]) {
sh 'docker login docker.ozg-sh.de -u ${USER} -p ${PASSWORD}'
//sh './mvnw -s $MAVEN_SETTINGS clean package -Pnative -DskipTests'
sh 'docker build -f src/main/docker/Dockerfile.native -t docker.ozg-sh.de/user-manager:build-latest .'
//sh './mvnw -s $MAVEN_SETTINGS verify -Pnative'
sleep time: 10000, unit: 'MILLISECONDS'
}
}
}
}
}
stage('Push Docker image') { stage('Push Docker image') {
steps { steps {
script { script {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment