diff --git a/.github/workflows/build_and_push_container_to_ghcrio.yml b/.github/workflows/build_and_push_container_to_ghcrio.yml index 5b0a8825..caaa5d9a 100644 --- a/.github/workflows/build_and_push_container_to_ghcrio.yml +++ b/.github/workflows/build_and_push_container_to_ghcrio.yml @@ -35,15 +35,15 @@ jobs: fi # Output the tag name - echo "::set-output name=tag_name::${tag_name}" + echo "tag_name=${tag_name}" >> "${GITHUB_OUTPUT}" # Get repository name in lower - name: get lowercase repo name id: get_lowercase_repo_name - run: echo "::set-output name=repo_name::$(tr '[:upper:]' '[:lower:]' <<< "${{ github.repository }}")" + run: echo "repo_name=$(tr '[:upper:]' '[:lower:]' <<< "${{ github.repository }}")" >> "${GITHUB_OUTPUT}" # Set platforms - name: Set platforms id: set_platforms - run: echo '::set-output name=platforms::["linux/amd64"]' + run: echo 'platforms=["linux/amd64"]' >> "${GITHUB_OUTPUT}" outputs: tag_name: ${{ steps.get_tag_name.outputs.tag_name }} repo_name: ${{ steps.get_lowercase_repo_name.outputs.repo_name }} @@ -63,13 +63,13 @@ jobs: # Platform to tag suffix - name: Platform to tag suffix id: platform_to_tag_suffix - run: echo "::set-output name=platform_tag::$( echo ${{ matrix.platform }} | tr '/' '-' )" + run: echo "platform_tag=$( echo ${{ matrix.platform }} | tr '/' '-' )" >> "${GITHUB_OUTPUT}" # Use qemu to perform multiplatform builds - name: Set up QEMU - uses: docker/setup-qemu-action@v1 + uses: docker/setup-qemu-action@v2 # Use docker buildx to build multi-platform containers - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 + uses: docker/setup-buildx-action@v2 with: use: true install: true @@ -78,18 +78,19 @@ jobs: max-parallelism = 2 # Log in to GitHub Container registry - name: Login to GitHub Container Registry - uses: docker/login-action@v1 + uses: docker/login-action@v2 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} # Build and push docker images - name: Build and Push Docker Image - uses: docker/build-push-action@v2 + uses: docker/build-push-action@v4 with: context: . file: envm/Dockerfile platforms: ${{ matrix.platform }} + provenance: false push: true tags: ghcr.io/${{ needs.get_parameters.outputs.repo_name }}:${{ needs.get_parameters.outputs.tag_name }}-${{ steps.platform_to_tag_suffix.outputs.platform_tag }} @@ -103,7 +104,7 @@ jobs: uses: actions/checkout@v3 # Log in to GitHub Container registry - name: Login to GitHub Container Registry - uses: docker/login-action@v1 + uses: docker/login-action@v2 with: registry: ghcr.io username: ${{ github.actor }} @@ -165,7 +166,7 @@ jobs: < "${GITHUB_EVENT_PATH}" \ )" # Set output - echo "::set-output name=branch_name::${ref%refs/heads/}" + echo "branch_name=${ref%refs/heads/}" >> "${GITHUB_OUTPUT}" # Not so standard checkout step # Need to checkout PR - name: Checkout code