diff --git a/.github/actions/build-container-local/action.yaml b/.github/actions/build-container-local/action.yaml index 1a4f3ec..ea06c5d 100644 --- a/.github/actions/build-container-local/action.yaml +++ b/.github/actions/build-container-local/action.yaml @@ -66,6 +66,11 @@ inputs: required: false default: 'linux/amd64' + by_digest: + description: 'Whether to build and push the image by digest instead of tag' + required: false + default: false + outputs: image-list: description: >- @@ -163,7 +168,7 @@ runs: - name: Build and push Docker images id: build-and-push - if: success() && fromJSON(inputs.push_image) + if: success() && fromJSON(inputs.push_by_digest) uses: docker/build-push-action@v6 with: context: ${{ inputs.context }} @@ -178,7 +183,7 @@ runs: - name: Build Docker images id: build - if: success() && !fromJSON(inputs.push_image) + if: success() && !fromJSON(inputs.push_by_digest) uses: docker/build-push-action@v6 with: load: true diff --git a/.github/workflows/build-container.yml b/.github/workflows/build-container.yml index 6f6f0bb..fe33477 100644 --- a/.github/workflows/build-container.yml +++ b/.github/workflows/build-container.yml @@ -130,7 +130,7 @@ jobs: osg_repo: ${{ matrix.repo }} base_os: ${{ matrix.os }} platform: ${{ matrix.platform }} - push_image: true + push_by_digest: true output_image: ${{ steps.custom-image-name.outputs.output_image }} - name: Export digest