Skip to content

Commit

Permalink
feat: add multi-arch images for local use
Browse files Browse the repository at this point in the history
  • Loading branch information
Rob Ellison committed May 8, 2023
1 parent 950b80d commit 7b3e742
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 34 deletions.
35 changes: 1 addition & 34 deletions .github/workflows/auto-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@ jobs:
- name: Install semantic-release extra plugins
run: mv package.json package.json.bak && npm install --no-save @semantic-release/changelog @semantic-release-plus/docker && mv package.json.bak package.json

# - name: Set up QEMU
# uses: docker/setup-qemu-action@v2

# - name: Set up Docker Buildx
# uses: docker/setup-buildx-action@v2
# with:
# driver-opts: |
# image=moby/buildkit:v0.10.6

- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
Expand All @@ -53,28 +44,4 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx semantic-release


# - name: Create Release
# uses: actions/create-release@v1
# continue-on-error: true
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: ${{ steps.version_bump.outputs.version }}
# release_name: Release ${{ steps.version_bump.outputs.version }}
# body: "Automatic version bump: ${{ steps.version_bump.outputs.version }}"

# - name: Merge pull request
# run: |
# echo "Merging pull request #${{ github.event.pull_request.number }} created by ${{ github.event.pull_request.user.login }}"
# curl --request PUT \
# --url ${{ github.event.pull_request._links.merge.href }} \
# --header 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
# --header 'content-type: application/json' \
# --data '{
# "commit_title": "Automatically merge version update",
# "sha": "${{ github.event.pull_request.head.sha }}"
# }'



41 changes: 41 additions & 0 deletions .github/workflows/multi-arch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Build and publish Mulit-Arch Docker images

on:
workflow_dispatch:
push:
branches: [main]

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
driver-opts: |
image=moby/buildkit:v0.10.6
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build Docker Image
uses: docker/build-push-action@v3
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/airwalk-digital/airview-mdx-deck:main
secrets: |
"FONTAWESOME_NPM_AUTH_TOKEN=${{ secrets.FONTAWESOME_NPM_AUTH_TOKEN }}"

0 comments on commit 7b3e742

Please sign in to comment.