Can't figure out how to use Cloud Build + Gradle + Java 17 to build a Java Jar file. I can't find any example cloudbuild.yaml that uses Gradle 7.6, which is required for my Gradle build. I'm not trying to build an image, just a jar file. The project is stored in GCP Cloud Source and includes the Gradle Wrapper.
Here's the cloudbuild.yaml
steps:
- name: gradle:7.6-jdk17
args: ['build']
Here's the cloudbuild error
Status: Downloaded newer image for gradle:7.6-jdk17 docker.io/library/gradle:7.6-jdk17 ERROR ERROR: build step 0 "gradle:7.6-jdk17" failed: starting step container failed: Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "build": executable file not found in $PATH: unknown
tried searching for example cloudbuild.yaml files for Java 17 + Gradle 7.6 - no luck
tried using Google's examples, but they all use java 8