File tree Expand file tree Collapse file tree 1 file changed +38
-0
lines changed Expand file tree Collapse file tree 1 file changed +38
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Daily Docker Snapshot
2
+ on :
3
+ schedule : # to be pushed daily, at 07:00 PM (19:00)
4
+ - cron : ' 0 19 * * *' # NOTE: Only works if the workflow file is present in the default branch
5
+ jobs :
6
+ Pushing-Docker-Image :
7
+ runs-on : ubuntu-latest
8
+ steps :
9
+ - uses : actions/checkout@v2
10
+ with :
11
+ ref : develop # pushing the image from the develop branch
12
+
13
+ - name : Setting Up Docker Buildx # used for caching image layers, improves performance
14
+ id : buildx
15
+ uses : docker/setup-buildx-action@v1
16
+
17
+ - name : Login to Docker Hub
18
+ uses : docker/login-action@v1
19
+ with :
20
+ username : ${{ secrets.DOCKER_HUB_USERNAME }}
21
+ password : ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
22
+
23
+ - name : Get and Set Version
24
+ run : |
25
+ source ci/set-docker-image-version.sh
26
+ echo "version=${DOCKER_IMG_VER}" >> $GITHUB_ENV
27
+
28
+ - name : Build and push
29
+ uses : docker/build-push-action@v2
30
+ with :
31
+ context : .
32
+ builder : ${{ steps.buildx.outputs.name }}
33
+ file : ./Dockerfile
34
+ push : true
35
+ tags : ga4gh/ga4gh-starter-kit-common:snapshot # The docker image is tagged :snapshot
36
+ build-args : VERSION=${{ env.version }}
37
+ cache-from : type=gha # GitHub Actions Cache Exporter
38
+ cache-to : type=gha,mode=max
You can’t perform that action at this time.
0 commit comments