1 parent a6fd4f2 commit df3fb27Copy full SHA for df3fb27
1 file changed
.github/workflows/ghcr.yml
@@ -1,10 +1,11 @@
1
name: Build and push to GHCR
2
+
3
on:
4
push:
5
branches: [main]
6
paths:
7
- Containerfile
-
8
+ - .github/workflows/**
9
workflow_dispatch:
10
11
jobs:
@@ -20,6 +21,8 @@ jobs:
20
21
id: vars
22
run: echo "timestamp=$(date -u +'%Y%m%d-%H%M%S')" >> "$GITHUB_OUTPUT"
23
24
+ - uses: docker/setup-buildx-action@v3
25
26
- uses: docker/login-action@v3
27
with:
28
registry: ghcr.io
@@ -31,6 +34,8 @@ jobs:
31
34
context: .
32
35
file: Containerfile
33
36
push: true
37
+ cache-from: type=gha
38
+ cache-to: type=gha,mode=max
39
tags: |
- ghcr.io/${{ github.repository }}:${{ steps.vars.outputs.timestamp }}
40
ghcr.io/${{ github.repository }}:latest
41
+ ghcr.io/${{ github.repository }}:${{ steps.vars.outputs.timestamp }}
0 commit comments