Docker #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker | |
on: [workflow_dispatch] | |
jobs: | |
publish: | |
name: Build and Publish Docker image | |
strategy: | |
matrix: | |
arch: ["arm64", "armv7", "armv6", "armv5", "x86_64", "i386", "ppc64le"] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Authenticate Docker | |
uses: docker/[email protected] | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build | |
run: | | |
export SWIFT_BUILDROOT=$GITHUB_WORKSPACE | |
export SWIFT_TARGET_ARCH=${{ matrix.arch }} | |
$SWIFT_BUILDROOT/.devcontainer/build-scripts/build-docker.sh | |
- name: Archive Build artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: build-${{ matrix.arch }} | |
path: ./output/${{ matrix.arch }}/images |