Build multi-platform docker image
This commit is contained in:
parent
702b36a781
commit
dba6efe46e
|
@ -3,14 +3,14 @@ name: docker
|
|||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- '*'
|
||||
tags:
|
||||
- '*'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
|
@ -29,20 +29,24 @@ jobs:
|
|||
echo "REPOSITORY_LC=${REPOSITORY,,}" >>${GITHUB_ENV}
|
||||
env:
|
||||
REPOSITORY: '${{ github.repository }}'
|
||||
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v1
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
|
||||
- name: Login to Github registry
|
||||
uses: docker/login-action@v1
|
||||
|
||||
- name: Log in to Github registry
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
registry: ghcr.io
|
||||
|
||||
|
||||
- uses: docker/build-push-action@v2
|
||||
with:
|
||||
push: true
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: false # TODO: true
|
||||
tags: ghcr.io/${{ env.REPOSITORY_LC }}:${{ env.DOCKER_TAG }}
|
||||
|
||||
build_5_5:
|
||||
|
@ -79,6 +83,6 @@ jobs:
|
|||
|
||||
- uses: docker/build-push-action@v2
|
||||
with:
|
||||
push: true
|
||||
push: false # TODO: true
|
||||
file: Dockerfile@swift-5.5
|
||||
tags: ghcr.io/${{ env.REPOSITORY_LC }}:5.5-${{ env.DOCKER_TAG }}
|
||||
|
|
Loading…
Reference in New Issue