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 : Build Trickster image
2+ on :
3+ workflow_dispatch :
4+
5+ jobs :
6+ push :
7+ name : Build Trickster image
8+ runs-on : ubuntu-latest
9+ steps :
10+ - name : Checkout
11+ uses : actions/checkout@v4
12+ - name : Set up QEMU
13+ uses : docker/setup-qemu-action@v2
14+ - name : Set up Docker Buildx
15+ uses : docker/setup-buildx-action@v2
16+ - name : Login to GitHub Container Registry
17+ uses : docker/login-action@v2
18+ with :
19+ registry : ghcr.io
20+ username : ${{ github.actor }}
21+ password : ${{ secrets.GITHUB_TOKEN }}
22+ - name : Get short SHA
23+ run : echo "sha7=$(echo $GITHUB_SHA | cut -c1-7)" >> $GITHUB_ENV
24+ - name : Build and push
25+ uses : docker/build-push-action@v4
26+ with :
27+ file : " Dockerfile"
28+ push : true
29+ tags : >
30+ ghcr.io/${{ github.repository }}:${{ env.sha7 }}
31+ platforms : |
32+ linux/arm64
33+ linux/amd64
34+ - name : Output image tags
35+ run : |
36+ echo "## Built images with the following tags" >> $GITHUB_STEP_SUMMARY
37+ echo "### ghcr.io/${{ github.repository }}:${{ env.sha7 }}" >> $GITHUB_STEP_SUMMARY
You can’t perform that action at this time.
0 commit comments