File tree 1 file changed +32
-2
lines changed
1 file changed +32
-2
lines changed Original file line number Diff line number Diff line change 9
9
env :
10
10
REGISTRY : ghcr.io
11
11
IMAGE_NAME : " jr"
12
+ DOCKER-HUB-NAMESPACE : " jrndio"
12
13
13
14
jobs :
14
- docker-build :
15
+ docker-build-ghcr :
15
16
runs-on : ubuntu-latest
16
17
17
18
permissions :
39
40
context : .
40
41
push : true
41
42
platforms : linux/amd64,linux/arm64
42
- tags : ghcr.io/${{ github.repository_owner }}/jr:${{ github.ref_name }}
43
+ tags : ghcr.io/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}
44
+
45
+ docker-build-dockerhub :
46
+ runs-on : ubuntu-latest
47
+
48
+ permissions :
49
+ contents : read
50
+ packages : write
51
+
52
+ steps :
53
+ - name : Checkout
54
+ uses : actions/checkout@v4
55
+ - name : Set up QEMU
56
+ uses : docker/setup-qemu-action@v3
57
+ - name : Set up Docker Buildx
58
+ uses : docker/setup-buildx-action@v3
59
+ - name : Checkout repository
60
+ uses : actions/checkout@v4
61
+ - name : Log in to the Container registry
62
+ uses : docker/login-action@v3
63
+ with :
64
+ username : ${{ secrets.DOCKERHUB_USERNAME }}
65
+ password : ${{ secrets.DOCKERHUB_TOKEN }}
66
+ - name : Build and push docker image to ghcr.io
67
+ uses : docker/build-push-action@v5
68
+ with :
69
+ context : .
70
+ push : true
71
+ platforms : linux/amd64,linux/arm64
72
+ tags : ${{ env.DOCKER-HUB-NAMESPACE}}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}
You can’t perform that action at this time.
0 commit comments