File tree Expand file tree Collapse file tree 1 file changed +43
-0
lines changed Expand file tree Collapse file tree 1 file changed +43
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Build and Push Docker Image
2
+
3
+ on :
4
+ push :
5
+ tags :
6
+ - ' v*' # Trigger on tags'
7
+
8
+ jobs :
9
+ build-and-push :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ # Step 1: Checkout the repository code
13
+ - name : Checkout repository
14
+ uses : actions/checkout@v3
15
+
16
+ # Step 2: Set up QEMU for multi-platform builds
17
+ - name : Set up QEMU
18
+ uses : docker/setup-qemu-action@v2
19
+ with :
20
+ platforms : linux/amd64,linux/arm64
21
+
22
+ # Step 3: Set up Docker Buildx
23
+ - name : Set up Docker Buildx
24
+ uses : docker/setup-buildx-action@v2
25
+
26
+ # Step 4: Log in to Docker Hub
27
+ - name : Log in to Docker Hub
28
+ uses : docker/login-action@v2
29
+ with :
30
+ username : ${{ secrets.DOCKERHUB_USERNAME }}
31
+ password : ${{ secrets.DOCKERHUB_TOKEN }}
32
+
33
+ # Step 5: Build and push the Docker image
34
+ - name : Build and push Docker image
35
+ uses : docker/build-push-action@v4
36
+ with :
37
+ context : .
38
+ platforms : linux/amd64,linux/arm64
39
+ push : true
40
+ build-args : --progress=plain
41
+ tags : setavenger/blindbit-oracle:${{ github.ref_name }}
42
+
43
+
You can’t perform that action at this time.
0 commit comments