diff --git a/docker/action.yaml b/docker/action.yaml index 51a64bf..ce13095 100644 --- a/docker/action.yaml +++ b/docker/action.yaml @@ -8,9 +8,15 @@ inputs: tags: description: "Tags of image" required: true + push: + description: "Push image to registry after build" + required: false + default: "true" #FROM bellsoft/liberica-openjdk-alpine:21.0.6-10 runs: using: "composite" + secrets: + inherit steps: - name: "Config gradle" shell: bash @@ -22,8 +28,13 @@ runs: ENTRYPOINT ["java", "-jar", "/app.jar"] EOF + - name: "Login to Nexus" + shell: bash + run: | + echo '${{ secrets.NEXUS_PASSWORD }}' | buildah login --tls-verify=false -u '${{ secrets.NEXUS_USERNAME }}' --password-stdin nexus.isb - name: Build Docker Image uses: https://git.binom.pw/subochev/devops/build-docker@main with: image_name: ${{ inputs.image-name }} - tags: latest ${{ inputs.tags }} \ No newline at end of file + tags: latest ${{ inputs.tags }} + push: ${{ inputs.push }} \ No newline at end of file