From e8e32934166ce2fe4d36e5c61f7986be6ffada0c Mon Sep 17 00:00:00 2001 From: Teriuihi Date: Sat, 21 Jun 2025 00:59:42 +0200 Subject: [PATCH] Update Jenkinsfile to include Nexus credentials for Gradle build Integrated `NEXUS_CREDS` environment variable for secure handling of Nexus credentials during the Gradle shadowJar task. --- Jenkinsfile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 4025135..d427916 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,9 +1,12 @@ pipeline { agent any + environment { + NEXUS_CREDS = credentials('alttd-snapshot-user') + } stages { stage('Gradle') { steps { - sh 'bash gradlew shadowJar -x test' + sh './gradlew shadowJar -x test -PalttdSnapshotUsername=$NEXUS_CREDS_USR -PalttdSnapshotPassword=$NEXUS_CREDS_PSW' } } stage('Archive') { @@ -17,4 +20,4 @@ pipeline { } } } -} \ No newline at end of file +}