gpu wheels issue #5
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 & Publish Docker Image | |
| on: | |
| pull_request: | |
| branches: | |
| - docker | |
| paths: | |
| - 'docker/Dockerfile' | |
| - 'docker/requirements.txt' | |
| - 'docker/docker-compose.yml' | |
| - '.github/workflows/docker-publish.yml' | |
| push: | |
| branches: | |
| - docker | |
| paths: | |
| - 'docker/Dockerfile' | |
| - 'docker/requirements.txt' | |
| - 'docker/docker-compose.yml' | |
| - '.github/workflows/docker-publish.yml' | |
| jobs: | |
| build-and-push: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read # for checkout | |
| packages: write # to push to GHCR | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Set up QEMU (for multi-arch builds) | |
| uses: docker/setup-qemu-action@v2 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v2 | |
| - name: Log in to GitHub Container Registry | |
| uses: docker/login-action@v2 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build and push | |
| uses: docker/build-push-action@v3 | |
| with: | |
| context: . # or ./docker if you keep your Dockerfile there | |
| file: ./docker/Dockerfile # adjust path if needed | |
| push: true | |
| platforms: linux/amd64,linux/arm64 | |
| tags: | | |
| ghcr.io/deeptrackai/deep-learning-crash-course:latest | |
| ghcr.io/deeptrackai/deep-learning-crash-course:${{ github.sha }} |