Skip to content

Commit

Permalink
Merge pull request #6 from truenas/fix-gh-push-image
Browse files Browse the repository at this point in the history
Adapt github action for GHCR
  • Loading branch information
sonicaj authored Apr 23, 2024
2 parents e8bf9e5 + 4b67c7d commit dd7ae59
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions .github/workflows/docker_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,25 @@ name: build_image
on:
push:
branches:
- 'master_blocked'
- 'master'

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/setup-buildx-action@v2
- name: Login to GHCR
uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v3
with:
push: true
tags: ixsystems/apps_validation:latest
tags: ghcr.io/truenas/apps_validation:latest
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}

0 comments on commit dd7ae59

Please sign in to comment.