1414 - ' v[0-9]+.[0-9]+.[0-9]+*'
1515
1616env :
17- # Use docker.io for Docker Hub if empty
18- REGISTRY : docker.io
19- # github.repository as <account>/<repo>
20- IMAGE_NAME : pythongermany/webserv
17+ REGISTRY : ghcr.io
18+ IMAGE_NAME : webserv
2119
2220jobs :
2321 docker-cd :
2422 runs-on : ubuntu-latest
2523 permissions :
2624 contents : read
2725 packages : write
28- # This is used to complete the identity challenge
29- # with sigstore/fulcio when running outside of PRs.
26+ attestations : write
3027 id-token : write
3128
3229 steps :
3330 - name : Checkout repository
3431 uses : actions/checkout@v4
35-
36- # Set up BuildKit Docker container builder to be able to build
37- # multi-platform images and export cache
38- # https://github.com/docker/setup-buildx-action
39- - name : Set up Docker Buildx
40- uses : docker/setup-buildx-action@v3
4132
4233 # Login against a Docker registry except on PR
4334 # https://github.com/docker/login-action
@@ -46,16 +37,22 @@ jobs:
4637 uses : docker/login-action@v3
4738 with :
4839 registry : ${{ env.REGISTRY }}
49- username : ${{ vars.DOCKERHUB_USERNAME }}
50- password : ${{ secrets.DOCKERHUB_TOKEN }}
40+ username : ${{ github.actor }}
41+ password : ${{ secrets.GITHUB_TOKEN }}
42+
43+ # Set up BuildKit Docker container builder to be able to build
44+ # multi-platform images and export cache
45+ # https://github.com/docker/setup-buildx-action
46+ - name : Set up Docker Buildx
47+ uses : docker/setup-buildx-action@v3
5148
5249 # Extract metadata (tags, labels) for Docker
5350 # https://github.com/docker/metadata-action
54- - name : Extract Docker metadata
51+ - name : Extract metadata (tags, labels) for Docker
5552 id : meta
5653 uses : docker/metadata-action@v5
5754 with :
58- images : ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
55+ images : ${{ env.REGISTRY }}/${{ github.actor }}/${{ env.IMAGE_NAME }}
5956
6057 # Build and push Docker image with Buildx (don't push on PR)
6158 # https://github.com/docker/build-push-action
0 commit comments