diff --git a/Jenkinsfile b/Jenkinsfile index a7288e7b6..f891bec10 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -22,7 +22,7 @@ pipeline { } } steps { - sh 'scp -P 2225 -r script.sh admin@192.168.1.19:/home/admin/.' + sh 'scp -P 2225 -r script.sh admin@192.168.0.20:/home/admin/.' sh 'ssh -p 2225 admin@192.168.1.19 < script.sh' } } diff --git a/pom.xml b/pom.xml index 624f624e5..290fb2938 100644 --- a/pom.xml +++ b/pom.xml @@ -423,7 +423,7 @@ snapshots localhost.localdomain-snapshots - http://192.168.1.19:8081/artifactory/libs-snapshot-local + http://192.168.0.20:8081/artifactory/libs-snapshot-local diff --git a/script.sh b/script.sh index addc3020e..4464695e8 100644 --- a/script.sh +++ b/script.sh @@ -1,16 +1,16 @@ #!/bin/bash -wget http://192.168.1.19:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/maven-metadata.xml +wget http://192.168.0.20:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/maven-metadata.xml VERSION=$(cat maven-metadata.xml | grep -m 1 -oP '(?<=).*(?=)') rm -f maven-metadata.xml -wget http://192.168.1.19:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/$VERSION/maven-metadata.xml +wget http://192.168.0.20:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/$VERSION/maven-metadata.xml AID=$(cat maven-metadata.xml | grep -m 1 -oP '(?<=).*(?=)') VALUE=$(cat maven-metadata.xml | grep -m 1 -oP '(?<=).*(?=)') echo $AID-$VALUE.war > version #echo "curl \"http://192.168.0.56:8081/repository/maven-snapshots/org/springframework/samples/spring-petclinic/$VERSION/" > command -echo "curl \"http://192.168.1.19:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/$VERSION/" > command +echo "curl \"http://192.168.0.20:8081/artifactory/libs-snapshot-local/org/springframework/samples/spring-petclinic/$VERSION/" > command paste -d '' command version > firsthalf echo "\" -o /usr/share/tomcat/webapps/petclinic.war" > secondhalf