diff --git a/.github/workflows/docker-reused-steps/action.yml b/.github/workflows/docker-reused-steps/action.yml index 83620d7..079de05 100644 --- a/.github/workflows/docker-reused-steps/action.yml +++ b/.github/workflows/docker-reused-steps/action.yml @@ -3,14 +3,12 @@ name: Reusable docker workflow description: Reusable docker workflow. inputs: + DOCKERHUB_ORGANIZATION_NAME: + required: true DOCKERHUB_USERNAME: required: true DOCKERHUB_TOKEN: required: true - QUAY_USERNAME: - required: true - QUAY_TOKEN: - required: true tag: required: true @@ -21,7 +19,7 @@ runs: id: meta uses: docker/metadata-action@v5 with: - images: ${{ inputs.DOCKERHUB_USERNAME }}/twitcasting-recorder,ghcr.io/${{ github.repository_owner }}/twitcasting-recorder,quay.io/${{ github.repository_owner }}/twitcasting-recorder + images: ${{ inputs.DOCKERHUB_ORGANIZATION_NAME }}/twitcasting-recorder,ghcr.io/${{ github.repository_owner }}/twitcasting-recorder tags: | ${{ inputs.tag }} latest @@ -50,13 +48,6 @@ runs: username: ${{ github.repository_owner }} password: ${{ github.token }} - - name: Login to Quay Container Registry - uses: docker/login-action@v3 - with: - registry: quay.io - username: ${{ inputs.QUAY_USERNAME }} - password: ${{ inputs.QUAY_TOKEN }} - - name: Build and push uses: docker/build-push-action@v5 with: @@ -70,8 +61,5 @@ runs: VERSION=${{ inputs.tag }} RELEASE=${{ github.run_number }} platforms: linux/amd64,linux/arm64 - # Cache to regietry instead of gha to avoid the capacity limit. - cache-from: type=registry,ref=ghcr.io/${{ github.repository_owner }}/twitcasting-recorder:cache - cache-to: type=registry,ref=ghcr.io/${{ github.repository_owner }}/twitcasting-recorder:cache,mode=max sbom: true provenance: true diff --git a/.github/workflows/docker_publish.yml b/.github/workflows/docker_publish.yml index e51dcb4..29d0f19 100644 --- a/.github/workflows/docker_publish.yml +++ b/.github/workflows/docker_publish.yml @@ -34,8 +34,7 @@ jobs: - name: Build docker uses: ./.github/workflows/docker-reused-steps with: + DOCKERHUB_ORGANIZATION_NAME : ${{ secrets.DOCKERHUB_ORGANIZATION_NAME }} DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }} - QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }} - QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }} tag: ${{ github.ref_name }}