diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.yml index e398b22..dd40005 100644 --- a/.github/workflows/docker-build.yml +++ b/.github/workflows/docker-build.yml @@ -19,8 +19,21 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 + - name: Login to GitHub Container Registry + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Build Docker image - run: docker build -t build_test . + uses: docker/build-push-action@v4 + with: + context: . + load: true + tags: build_test:latest + cache-from: type=gha + cache-to: type=gha,mode=max - name: Run Docker container run: docker run --rm build_test -h