name: Docker on: workflow_dispatch: schedule: - cron: "0 0 * * 1" push: branches: - latest - dev jobs: build: name: build runs-on: ubuntu-latest permissions: packages: write contents: read steps: - name: Check out the repo uses: actions/checkout@v3 - name: Set up QEMU uses: docker/setup-qemu-action@v2 - name: Setup Docker buildx uses: docker/setup-buildx-action@v2 - name: Log in to Docker Hub uses: docker/login-action@v2 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} # - name: Log in to the Container registry # uses: docker/login-action@v2 # with: # registry: ghcr.io # username: ${{ github.actor }} # password: ${{ secrets.GIT_TOKEN }} - name: Extract metadata (tags, labels) for Docker id: meta uses: docker/metadata-action@v4 with: images: | ${{ secrets.DOCKERHUB_USERNAME }}/alpine_xfce4_novnc # ghcr.io/${{ github.repository }} - name: Build and push Docker images uses: docker/build-push-action@v3 with: context: . platforms: linux/amd64,linux/arm64,linux/arm/v7 #,linux/arm/v6, linux/386, linux/ppc64le,linux/s390x push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} cache-from: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/alpine_xfce4_novnc:buildcache cache-to: type=registry,ref=${{ secrets.DOCKERHUB_USERNAME }}/alpine_xfce4_novnc:buildcache,mode=max