Skip to content

Commit

Permalink
Combine push-image-ghcr/build-and-push-image job with release/docker-…
Browse files Browse the repository at this point in the history
…hub-release
  • Loading branch information
itskingori committed Oct 16, 2024
1 parent 4004cfa commit 353ce08
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 55 deletions.
54 changes: 0 additions & 54 deletions .github/workflows/push-image-ghcr.yml

This file was deleted.

13 changes: 12 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,19 @@ jobs:
runs-on: ubuntu-latest
env:
IMAGE: danihodovic/celery-exporter
permissions:
contents: write
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Prepare Image Metadata
id: metadata
uses: docker/metadata-action@v5
with:
images: ${{ env.IMAGE }}
images: |
${{ env.IMAGE }}
ghcr.io/${{ env.IMAGE }}
- name: Set Up QEMU
uses: docker/setup-qemu-action@v3
- name: Set Up Docker Buildx
Expand All @@ -43,6 +48,12 @@ jobs:
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: Login to Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build, tag, and push image to Docker Hub
uses: docker/build-push-action@v6
with:
Expand Down

0 comments on commit 353ce08

Please sign in to comment.