Troubleshooting arm64 builds #22
This file contains hidden or 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: Build Docker Container | |
| on: | |
| workflow_call: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| - devcontainer | |
| pull_request: | |
| branches: | |
| - main | |
| - devcontainer | |
| jobs: | |
| build-and-push: | |
| runs-on: ubuntu-latest | |
| name: Build Docker Image | |
| # strategy: | |
| # matrix: | |
| # platform: [linux/amd64, linux/arm64] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Set up QEMU | |
| uses: docker/setup-qemu-action@v3 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Login to DockerHub | |
| uses: docker/login-action@v3 | |
| with: | |
| username: ${{ secrets.DOCKERHUB_USERNAME }} | |
| password: ${{ secrets.DOCKERHUB_TOKEN }} | |
| - name: Build and Push | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| platform: linux/amd64,linux/arm64 | |
| push: true | |
| tags: | | |
| basictheprogram/crossfire-server:latest | |
| basictheprogram/crossfire-server:${{ github.sha }} | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max | |
| - name: Verify Image Architectures | |
| run: | | |
| docker manifest inspect basictheprogram/crossfire-server:latest |