modified Jenkinsfile

This commit is contained in:
hllvc 2021-07-11 12:40:06 +02:00
parent 2926df3357
commit 5d79ac805e

5
Jenkinsfile vendored
View file

@ -19,8 +19,7 @@ pipeline {
stage('MySQL setup') { stage('MySQL setup') {
steps { steps {
sh 'docker network create petclinic || true' sh 'docker run -d --name petclinic-mysql -e MYSQL_USER=petclinic -e MYSQL_PASSWORD=petclinic -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=petclinic -p 3306:3306 mysql:5.7.8'
sh 'docker run -d --network petclinic -e MYSQL_USER=petclinic -e MYSQL_PASSWORD=petclinic -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=petclinic -p 3306:3306 mysql:5.7.8'
} }
} }
@ -28,7 +27,7 @@ pipeline {
agent { agent {
dockerfile { dockerfile {
filename 'Dockerfile.run' filename 'Dockerfile.run'
args '-d -v $HOME/app:/root/app --network petclinic' args '-d -v $HOME/app:/root/app --link petclinic-mysql'
} }
} }
steps { steps {