Skip to content

Commit 8e3fda6

Browse files
committed
Authenticate with artifactory.
See #2208.
1 parent f7bf8a0 commit 8e3fda6

File tree

5 files changed

+38
-6
lines changed

5 files changed

+38
-6
lines changed

Jenkinsfile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ pipeline {
2626

2727
environment {
2828
DOCKER_HUB = credentials('hub.docker.com-springbuildmaster')
29+
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
2930
}
3031

3132
steps {
@@ -57,6 +58,7 @@ pipeline {
5758

5859
environment {
5960
DOCKER_HUB = credentials('hub.docker.com-springbuildmaster')
61+
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
6062
}
6163

6264
steps {
@@ -80,6 +82,7 @@ pipeline {
8082

8183
environment {
8284
DOCKER_HUB = credentials('hub.docker.com-springbuildmaster')
85+
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
8386
}
8487

8588
steps {
@@ -117,7 +120,7 @@ pipeline {
117120
script {
118121
docker.withRegistry('', 'hub.docker.com-springbuildmaster') {
119122
docker.image('adoptopenjdk/openjdk8:latest').inside('-v $HOME:/tmp/jenkins-home') {
120-
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -Pci,artifactory -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j-non-root ' +
123+
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -s settings.xml -Pci,artifactory -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j-non-root ' +
121124
'-Dartifactory.server=https://repo.spring.io ' +
122125
"-Dartifactory.username=${ARTIFACTORY_USR} " +
123126
"-Dartifactory.password=${ARTIFACTORY_PSW} " +
@@ -148,7 +151,7 @@ pipeline {
148151
script {
149152
docker.withRegistry('', 'hub.docker.com-springbuildmaster') {
150153
docker.image('adoptopenjdk/openjdk8:latest').inside('-v $HOME:/tmp/jenkins-home') {
151-
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -Pci,distribute -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j-non-root ' +
154+
sh 'MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -s settings.xml -Pci,distribute -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j-non-root ' +
152155
'-Dartifactory.server=https://repo.spring.io ' +
153156
"-Dartifactory.username=${ARTIFACTORY_USR} " +
154157
"-Dartifactory.password=${ARTIFACTORY_PSW} " +

LICENSE.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,15 +179,15 @@
179179
APPENDIX: How to apply the Apache License to your work.
180180

181181
To apply the Apache License to your work, attach the following
182-
boilerplate notice, with the fields enclosed by brackets "[]"
182+
boilerplate notice, with the fields enclosed by brackets "{}"
183183
replaced with your own identifying information. (Don't include
184184
the brackets!) The text should be enclosed in the appropriate
185185
comment syntax for the file format. We also recommend that a
186186
file or class name and description of purpose be included on the
187187
same "printed page" as the copyright notice for easier
188188
identification within third-party archives.
189189

190-
Copyright [yyyy] [name of copyright owner]
190+
Copyright {yyyy} {name of copyright owner}
191191

192192
Licensed under the Apache License, Version 2.0 (the "License");
193193
you may not use this file except in compliance with the License.

ci/clean.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
set -euo pipefail
44

55
MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" \
6-
./mvnw clean -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j
6+
./mvnw -s settings.xml clean -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j

ci/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ set -euo pipefail
55
mkdir -p /tmp/jenkins-home
66
chown -R 1001:1001 .
77
MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" \
8-
./mvnw -P${PROFILE} clean dependency:list verify -Dsort -U -B -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j
8+
./mvnw -s settings.xml -P${PROFILE} clean dependency:list verify -Dsort -U -B -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-neo4j

settings.xml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
2+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
4+
https://maven.apache.org/xsd/settings-1.0.0.xsd">
5+
6+
<servers>
7+
<server>
8+
<id>spring-plugins-release</id>
9+
<username>${env.ARTIFACTORY_USR}</username>
10+
<password>${env.ARTIFACTORY_PSW}</password>
11+
</server>
12+
<server>
13+
<id>spring-libs-snapshot</id>
14+
<username>${env.ARTIFACTORY_USR}</username>
15+
<password>${env.ARTIFACTORY_PSW}</password>
16+
</server>
17+
<server>
18+
<id>spring-libs-milestone</id>
19+
<username>${env.ARTIFACTORY_USR}</username>
20+
<password>${env.ARTIFACTORY_PSW}</password>
21+
</server>
22+
<server>
23+
<id>spring-libs-release</id>
24+
<username>${env.ARTIFACTORY_USR}</username>
25+
<password>${env.ARTIFACTORY_PSW}</password>
26+
</server>
27+
</servers>
28+
29+
</settings>

0 commit comments

Comments
 (0)