File tree Expand file tree Collapse file tree 2 files changed +49
-0
lines changed
Expand file tree Collapse file tree 2 files changed +49
-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+ branches :
6+ - " dockerfile"
7+ workflow_dispatch :
8+
9+ jobs :
10+ build-and-push-image :
11+ if : ${{ github.repository == 'DiamondLightSource/httomolibgpu' }}
12+ runs-on : ubuntu-latest
13+ permissions :
14+ contents : read
15+ packages : write
16+
17+ steps :
18+ - name : Checkout repository
19+ uses : actions/checkout@v4
20+
21+ - name : Log in to the Container registry
22+ uses : docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
23+ with :
24+ registry : ghcr.io
25+ username : ${{ github.actor }}
26+ password : ${{ secrets.GITHUB_TOKEN }}
27+
28+ - name : Extract metadata (tags, labels) for Docker
29+ id : meta
30+ uses : docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
31+ with :
32+ images : |
33+ ghcr.io/${{ github.repository }}
34+ tags : |
35+ type=edge,branch=main
36+ type=ref,event=branch
37+ type=semver,pattern={{version}}
38+
39+ - name : Build and push Docker image
40+ uses : docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
41+ with :
42+ context : .
43+ push : true
44+ tags : ${{ steps.meta.outputs.tags }}
45+ labels : ${{ steps.meta.outputs.labels }}
Original file line number Diff line number Diff line change 1+ FROM nvidia/cuda:11.6.2-devel-ubi8
2+
3+ RUN dnf install -y git && \
4+ dnf clean all
You can’t perform that action at this time.
0 commit comments