Fix: Run docker login for gradle build jobs 85/71885/4
authorJessica Wagantall <jwagantall@linuxfoundation.org>
Thu, 29 Jun 2023 20:58:50 +0000 (13:58 -0700)
committerJessica Wagantall <jwagantall@linuxfoundation.org>
Fri, 30 Jun 2023 21:53:20 +0000 (14:53 -0700)
Issue: RELENG-4763
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
Change-Id: I24aa3a8a8982a048d760d3012b9645e2689e8996

.jjb-test/lf-gradle-jobs.yaml
docs/jjb/lf-gradle-jobs.rst
jjb/lf-gradle-jobs.yaml
releasenotes/notes/gradle-jobs-docker-login-bc3ad0a3d42d19a7.yaml [new file with mode: 0644]

index cba1590..4b375de 100644 (file)
@@ -5,6 +5,7 @@
       - gerrit-gradle-build
 
     project-name: gerrit-gradle
+    mvn-settings: gerrit-maven-project-settings
 
 - project:
     name: github-gradle-jobs
@@ -13,6 +14,7 @@
 
     github-org: fake-org
     project-name: github-gradle
+    mvn-settings: gerrit-maven-project-settings
 
 - project:
     name: gradle-jobs-view
@@ -20,3 +22,4 @@
       - project-view
 
     project-name: gradle
+    mvn-settings: gerrit-maven-project-settings
index 3bc0c34..354edb9 100644 (file)
@@ -20,6 +20,7 @@ Runs a gradle build command to perform the verification.
     :build-node:    The node to run build on.
     :java-version: Version of Java to execute Maven build. (default: openjdk17)
     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
+    :mvn-settings: Maven settings.xml file containing credentials to use.
 
 :Optional parameters:
 
index cd4f4d6..4db41f2 100644 (file)
@@ -80,6 +80,9 @@
       - lf-infra-pre-build
       - lf-update-java-alternatives:
           java-version: "{java-version}"
+      - lf-infra-docker-login:
+          global-settings-file: "global-settings"
+          settings-file: "{mvn-settings}"
       - shell: |
           ./gradlew build
 
     <<: *lf_gradle_common
 
     builders:
+      - lf-infra-pre-build
+      - lf-update-java-alternatives:
+          java-version: "{java-version}"
+      - lf-infra-docker-login:
+          global-settings-file: "global-settings"
+          settings-file: "{mvn-settings}"
       - shell: |
           ./gradlew build
 
diff --git a/releasenotes/notes/gradle-jobs-docker-login-bc3ad0a3d42d19a7.yaml b/releasenotes/notes/gradle-jobs-docker-login-bc3ad0a3d42d19a7.yaml
new file mode 100644 (file)
index 0000000..f65c4a1
--- /dev/null
@@ -0,0 +1,5 @@
+---
+fixes:
+  - |
+    Gradle build job needs to run docker login step to allow
+    docker operations and access to Nexus3.