File tree Expand file tree Collapse file tree 2 files changed +46
-14
lines changed
Expand file tree Collapse file tree 2 files changed +46
-14
lines changed Original file line number Diff line number Diff line change 1+ name : Dockerize
2+
3+ on :
4+ # schedule:
5+ # - cron: "0 10 * * *" # everyday at 10am
6+ push :
7+ branches :
8+ - main
9+ - dev
10+ tags :
11+ - " *"
12+ pull_request :
13+
14+ jobs :
15+ docker :
16+ runs-on : ubuntu-latest
17+ steps :
18+ - uses : actions/checkout@v2
19+ - name : Docker meta
20+ id : docker_meta
21+ uses : crazy-max/ghaction-docker-meta@v1.8.4
22+ with :
23+ images : inseefrlab/rstudio-gpu # list of Docker images to use as base name for tags
24+ - name : Set up QEMU
25+ uses : docker/setup-qemu-action@v1
26+ - name : Set up Docker Buildx
27+ uses : docker/setup-buildx-action@v1
28+ - name : Login to DockerHub
29+ if : github.event_name != 'pull_request'
30+ uses : docker/login-action@v1
31+ with :
32+ username : ${{ secrets.DOCKERHUB_USERNAME }}
33+ password : ${{ secrets.DOCKERHUB_TOKEN }}
34+ - name : Build and push
35+ uses : docker/build-push-action@v2
36+ with :
37+ context : .
38+ file : ./Dockerfile
39+ push : ${{ github.event_name != 'pull_request' }}
40+ # Use tags computed before and also latest if on master
41+ tags : |
42+ ${{ steps.docker_meta.outputs.tags }}
43+ ${{ github.ref == 'refs/heads/master' && 'inseefrlab/rstudio-gpu:latest' || '' }}
44+ labels : ${{ steps.docker_meta.outputs.labels }}
45+ - name : Image digest
46+ run : echo ${{ steps.docker_build.outputs.digest }}
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments