From a53daf777c70b183132ffd049ce645332eb2d3d3 Mon Sep 17 00:00:00 2001 From: talesmarra Date: Fri, 16 Sep 2022 18:42:29 +0200 Subject: [PATCH] test --- .github/workflows/deploy.yml | 31 ++++++++++++------------------- 1 file changed, 12 insertions(+), 19 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 8f7c53f..cd49073 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -27,29 +27,22 @@ jobs: name: pkg_wheel path: dist/*.tar.gz - deploy_docker_image_to_hub: - name: Push Docker image to Docker Hub + deploy_docker_image: runs-on: ubuntu-latest steps: - - name: Check out the repository - uses: actions/checkout@v3 - - - name: Log in to Docker Hub - uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9 + - name: Login to Docker Hub + uses: docker/login-action@v1 with: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} - - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38 - with: - images:marratales/myimage - - - name: Build and push Docker image - uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 with: - context: . + context: ./ + file: ./Dockerfile + builder: ${{ steps.buildx.outputs.name }} push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} + tags: ${{ secrets.DOCKER_HUB_USERNAME }}/myimage:latest + cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/myimage:buildcache + cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/myimage:buildcache,mode=max + cache: "enabled"