Skip to content

Commit

Permalink
Add harmony-yggdrasil Docker images
Browse files Browse the repository at this point in the history
  • Loading branch information
neilalexander committed Oct 20, 2024
1 parent 16dc800 commit 8bf9572
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,56 @@ jobs:
tags: |
ghcr.io/${{ env.GHCR_NAMESPACE }}/harmony:latest
ghcr.io/${{ env.GHCR_NAMESPACE }}/harmony:${{ env.RELEASE_VERSION }}
yggdrasil:
name: Yggdrasil image
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get release tag & build flags
if: github.event_name == 'release' # Only for GitHub releases
run: |
echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Containers
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build Yggdrasil image
if: github.ref_name == 'main' || github.event_name == 'workflow_dispatch'
id: docker_build_monolith
uses: docker/build-push-action@v3
with:
cache-from: type=gha
cache-to: type=gha,mode=max
context: .
file: Dockerfile.yggdrasil
platforms: ${{ env.PLATFORMS }}
push: true
tags: |
ghcr.io/${{ env.GHCR_NAMESPACE }}/harmony-yggdrasil:${{ github.ref_name }}
- name: Build release Yggdrasil image
if: github.event_name == 'release' # Only for GitHub releases
id: docker_build_monolith_release
uses: docker/build-push-action@v3
with:
cache-from: type=gha
cache-to: type=gha,mode=max
context: .
file: Dockerfile.yggdrasil
platforms: ${{ env.PLATFORMS }}
push: true
tags: |
ghcr.io/${{ env.GHCR_NAMESPACE }}/harmony-yggdrasil:latest
ghcr.io/${{ env.GHCR_NAMESPACE }}/harmony-yggdrasil:${{ env.RELEASE_VERSION }}

0 comments on commit 8bf9572

Please sign in to comment.