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 and Push Docker Image
2+
3+ on :
4+ workflow_dispatch :
5+
6+ push :
7+ tags :
8+ - ' [0-9]+.[0-9]+.[0-9]+'
9+
10+ env :
11+ IMAGE_NAME : kjuly/ruby-alpine-build-base
12+
13+ permissions :
14+ contents : read
15+ packages : write
16+ id-token : write
17+ attestations : write
18+
19+ concurrency :
20+ group : " images"
21+ cancel-in-progress : false
22+
23+ jobs :
24+ build-n-push-image :
25+ runs-on : ubuntu-latest
26+ steps :
27+ - name : Checkout
28+ uses : actions/checkout@v4
29+
30+ - name : Build and Push Image to Docker Hub
31+ uses : kjuly/docker-image-publisher@main
32+ with :
33+ image_name : ${{ env.IMAGE_NAME }}
34+ username : ${{ secrets.DOCKERHUB_USERNAME }}
35+ token : ${{ secrets.DOCKERHUB_TOKEN }}
36+
37+ - name : Build and Push Image to Github Container Registry
38+ uses : kjuly/docker-image-publisher@main
39+ with :
40+ registry : ghcr.io
41+ image_name : ${{ env.IMAGE_NAME }}
42+ username : ${{ github.actor }}
43+ token : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments