File tree 1 file changed +38
-0
lines changed
1 file changed +38
-0
lines changed Original file line number Diff line number Diff line change
1
+ # SPDX-FileCopyrightText: 2024 Kaushlendra Pratap <[email protected] >
2
+ # SPDX-License-Identifier: GPL-2.0-only
3
+
4
+ name : Build and Push Docker Image
5
+
6
+ on :
7
+ push :
8
+ branches :
9
+ - main
10
+
11
+ jobs :
12
+ docker-build :
13
+ runs-on : ubuntu-latest
14
+
15
+ steps :
16
+ - name : Checkout repository
17
+ uses : actions/checkout@v3
18
+
19
+ - name : Set up Docker Buildx
20
+ uses : docker/setup-buildx-action@v2
21
+
22
+ - name : Log in to Docker Hub
23
+ uses : docker/login-action@v2
24
+ with :
25
+ username : ${{ secrets.DOCKERHUB_USERNAME }}
26
+ password : ${{ secrets.DOCKERHUB_TOKEN }}
27
+
28
+ - name : Build and push main image
29
+ uses : docker/build-push-action@v4
30
+ with :
31
+ push : true
32
+ tags : fossology/licensedb:latest
33
+ context : .
34
+ cache-from : type=gha
35
+ cache-to : type=gha,mode=max
36
+
37
+ - name : Log out from Docker Hub
38
+ run : docker logout
You can’t perform that action at this time.
0 commit comments