Authenticate with artifactory.

This commit is contained in:
Greg L. Turnquist
2021-04-14 14:39:12 -05:00
parent 3f5707c9e2
commit 014bf6f99a
5 changed files with 26 additions and 32 deletions

2
Jenkinsfile vendored
View File

@@ -214,7 +214,7 @@ pipeline {
steps {
script {
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -Pdistribute,docs ' +
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -s settings.xml -Pdistribute,docs ' +
'-Dartifactory.server=https://repo.spring.io ' +
"-Dartifactory.username=${ARTIFACTORY_USR} " +
"-Dartifactory.password=${ARTIFACTORY_PSW} " +

View File

@@ -8,4 +8,4 @@ set -euo pipefail
echo 'Deploying to Artifactory...'
MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" \
./mvnw -P${PROFILE} -Dmaven.test.skip=true clean deploy -B
./mvnw -s settings.xml -P${PROFILE} -Dmaven.test.skip=true clean deploy -B

View File

@@ -3,4 +3,4 @@
set -euo pipefail
MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" \
./mvnw -P${PROFILE} clean dependency:list test -Dsort -B
./mvnw -s settings.xml -P${PROFILE} clean dependency:list test -Dsort -B

32
pom.xml
View File

@@ -312,32 +312,6 @@
<spring.version>5.1.3.BUILD-SNAPSHOT</spring.version>
<spring-security.version>5.1.2.BUILD-SNAPSHOT</spring-security.version>
</properties>
<repositories>
<repository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/snapshot</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/milestone</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>spring-release</id>
<name>Spring Releases</name>
<url>https://repo.spring.io/release</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
</profile>
<profile>
@@ -907,7 +881,7 @@
<pluginRepositories>
<pluginRepository>
<id>spring-snapshots</id>
<id>spring-libs-snapshot</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/libs-snapshot</url>
<snapshots>
@@ -915,12 +889,12 @@
</snapshots>
</pluginRepository>
<pluginRepository>
<id>spring-milestones</id>
<id>spring-libs-milestone</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/libs-milestone</url>
</pluginRepository>
<pluginRepository>
<id>spring-releases</id>
<id>spring-libs-release</id>
<name>Spring Releases</name>
<url>https://repo.spring.io/libs-release</url>
</pluginRepository>

View File

@@ -9,6 +9,26 @@
<username>${env.SONATYPE_USR}</username>
<password>${env.SONATYPE_PSW}</password>
</server>
<server>
<id>spring-plugins-release</id>
<username>${env.ARTIFACTORY_USR}</username>
<password>${env.ARTIFACTORY_PSW}</password>
</server>
<server>
<id>spring-libs-snapshot</id>
<username>${env.ARTIFACTORY_USR}</username>
<password>${env.ARTIFACTORY_PSW}</password>
</server>
<server>
<id>spring-libs-milestone</id>
<username>${env.ARTIFACTORY_USR}</username>
<password>${env.ARTIFACTORY_PSW}</password>
</server>
<server>
<id>spring-libs-release</id>
<username>${env.ARTIFACTORY_USR}</username>
<password>${env.ARTIFACTORY_PSW}</password>
</server>
</servers>
</settings>