File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Docker Build
2+
3+ on :
4+ push :
5+ branches : ["master"]
6+
7+ jobs :
8+ build :
9+ runs-on : ubuntu-latest
10+ permissions :
11+ contents : read
12+ packages : write
13+ steps :
14+ - name : Checkout code
15+ uses : actions/checkout@v6
16+ - name : Set up QEMU
17+ uses : docker/setup-qemu-action@v4
18+ - name : Set up Docker Buildx
19+ uses : docker/setup-buildx-action@v4
20+ - name : Login to GitHub Container Registry
21+ uses : docker/login-action@v4
22+ with :
23+ registry : ghcr.io
24+ username : ${{ github.actor }}
25+ password : ${{ secrets.GITHUB_TOKEN }}
26+ - name : Build and push Docker image
27+ uses : docker/build-push-action@v7
28+ with :
29+ context : .
30+ push : true
31+ platforms : linux/amd64,linux/arm64
32+ tags : ghcr.io/${{ github.repository }}:latest
33+ cache-from : type=gha
34+ cache-to : type=gha,mode=max
You can’t perform that action at this time.
0 commit comments