From 58b07d0d0d7459c0c279b28cdce801461f1f28e2 Mon Sep 17 00:00:00 2001 From: Anthony Stirling <77850077+Frooodle@users.noreply.github.com> Date: Mon, 24 Feb 2025 13:48:42 +0000 Subject: [PATCH] Update push-docker.yml --- .github/workflows/push-docker.yml | 75 ------------------------------- 1 file changed, 75 deletions(-) diff --git a/.github/workflows/push-docker.yml b/.github/workflows/push-docker.yml index 795a337af..12c20ecaa 100644 --- a/.github/workflows/push-docker.yml +++ b/.github/workflows/push-docker.yml @@ -75,81 +75,6 @@ jobs: id: repoowner run: echo "lowercase=$(echo ${{ github.repository_owner }} | awk '{print tolower($0)}')" >> $GITHUB_OUTPUT - - name: Generate tags - id: meta - uses: docker/metadata-action@369eb591f429131d6889c46b94e711f089e6ca96 # v5.6.1 - with: - images: | - ${{ secrets.DOCKER_HUB_USERNAME }}/s-pdf - ghcr.io/${{ steps.repoowner.outputs.lowercase }}/s-pdf - ghcr.io/${{ steps.repoowner.outputs.lowercase }}/stirling-pdf - ${{ secrets.DOCKER_HUB_ORG_USERNAME }}/stirling-pdf - tags: | - type=raw,value=${{ steps.versionNumber.outputs.versionNumber }},enable=${{ github.ref == 'refs/heads/master' }} - type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }} - type=raw,value=alpha,enable=${{ github.ref == 'refs/heads/main' }} - - - name: Build and push main Dockerfile - id: build-push-regular - uses: docker/build-push-action@0adf9959216b96bec444f325f1e493d4aa344497 # v6.14.0 - with: - builder: ${{ steps.buildx.outputs.name }} - context: . - file: ./Dockerfile - push: true - cache-from: type=gha - cache-to: type=gha,mode=max - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - build-args: VERSION_TAG=${{ steps.versionNumber.outputs.versionNumber }} - platforms: linux/amd64,linux/arm64/v8 - provenance: true - sbom: true - - - name: Sign regular images - if: github.ref == 'refs/heads/master' - env: - DIGEST: ${{ steps.build-push-regular.outputs.digest }} - TAGS: ${{ steps.meta.outputs.tags }} - COSIGN_PRIVATE_KEY: ${{ secrets.COSIGN_PRIVATE_KEY }} - COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }} - run: | - echo "$TAGS" | tr ',' '\n' | while read -r tag; do - cosign sign --yes \ - --key env://COSIGN_PRIVATE_KEY \ - "${tag}@${DIGEST}" - done - - - name: Generate tags ultra-lite - id: meta2 - uses: docker/metadata-action@369eb591f429131d6889c46b94e711f089e6ca96 # v5.6.1 - if: github.ref != 'refs/heads/main' - with: - images: | - ${{ secrets.DOCKER_HUB_USERNAME }}/s-pdf - ghcr.io/${{ steps.repoowner.outputs.lowercase }}/s-pdf - ghcr.io/${{ steps.repoowner.outputs.lowercase }}/stirling-pdf - ${{ secrets.DOCKER_HUB_ORG_USERNAME }}/stirling-pdf - tags: | - type=raw,value=${{ steps.versionNumber.outputs.versionNumber }}-ultra-lite,enable=${{ github.ref == 'refs/heads/master' }} - type=raw,value=latest-ultra-lite,enable=${{ github.ref == 'refs/heads/master' }} - - - name: Build and push Dockerfile-ultra-lite - id: build-push-lite - uses: docker/build-push-action@0adf9959216b96bec444f325f1e493d4aa344497 # v6.14.0 - if: github.ref != 'refs/heads/main' - with: - context: . - file: ./Dockerfile.ultra-lite - push: true - cache-from: type=gha - cache-to: type=gha,mode=max - tags: ${{ steps.meta2.outputs.tags }} - labels: ${{ steps.meta2.outputs.labels }} - build-args: VERSION_TAG=${{ steps.versionNumber.outputs.versionNumber }} - platforms: linux/amd64,linux/arm64/v8 - provenance: true - sbom: true - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v4