Skip to content

Commit

Permalink
Fix build (#96)
Browse files Browse the repository at this point in the history
Co-authored-by: Daniel Beck <[email protected]>
  • Loading branch information
timja and daniel-beck authored Oct 12, 2024
1 parent 242aa3a commit fc767e9
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 12 deletions.
13 changes: 4 additions & 9 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,24 @@ properties([
])
])

def javaVersion = '17'

node('linux-amd64') {
stage ('Prepare') {
deleteDir()
checkout scm
}

stage ('Build') {
infra.runMaven(["clean", "verify"], '11')
infra.runMaven(["clean", "verify"], javaVersion)
}

stage ('Generate') {
// fetch the Maven settings with artifact caching proxy in a
// tmp folder, and set MAVEN_SETTINGS env var to its absolute
// location
infra.withArtifactCachingProxy {
repositoryOrigin = "https://repo." + (env.ARTIFACT_CACHING_PROXY_PROVIDER ?: 'azure') + ".jenkins.io"
withEnv(["ARTIFACT_CACHING_PROXY_ORIGIN=$repositoryOrigin"]) {
withCredentials([usernamePassword(credentialsId: 'artifact-caching-proxy-credentials',
usernameVariable: 'ARTIFACT_CACHING_PROXY_USERNAME',
passwordVariable: 'ARTIFACT_CACHING_PROXY_PASSWORD')]) {
infra.runWithMaven('java -jar target/extension-indexer-*-bin/extension-indexer-*.jar -adoc dist', '11')
}
}
infra.runWithMaven('java -jar target/extension-indexer-*-bin/extension-indexer-*.jar -adoc dist', javaVersion)
}
}

Expand Down
37 changes: 34 additions & 3 deletions maven-settings.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,40 @@
<settings>
<activeProfiles>
<activeProfile>jenkins</activeProfile>
</activeProfiles>
<profiles>
<profile>
<id>jenkins</id>
<repositories>
<repository>
<id>jenkins-public</id>
<url>https://repo.jenkins-ci.org/public/</url>
<releases>
<enabled>true</enabled>
</releases>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>jenkins-public</id>
<url>https://repo.jenkins-ci.org/public/</url>
<releases>
<enabled>true</enabled>
</releases>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<mirrors>
<mirror>
<id>repo.jenkins-ci.org</id>
<url>https://repo.jenkins-ci.org/public/</url>
<mirrorOf>*</mirrorOf>
<id>repo.j.o-mirror</id>
<mirrorOf>repo.jenkins-ci.org</mirrorOf>
<url>https://repo.jenkine-ci.org/public/</url>
</mirror>
<mirror>
<id>m.g.o-public-repo1</id>
<mirrorOf>m.g.o-public</mirrorOf>
<url>https://repo.maven.apache.org/maven2/</url>
</mirror>
</mirrors>
</settings>

0 comments on commit fc767e9

Please sign in to comment.