File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Build and publish hello container
2+
3+ on :
4+ push :
5+ branches : [ "main" ]
6+
7+ permissions :
8+ contents : read
9+ packages : write
10+
11+ env :
12+ REGISTRY : ghcr.io
13+ IMAGE_NAME : hello
14+
15+ jobs :
16+ build-and-push :
17+ runs-on : ubuntu-latest
18+
19+ steps :
20+ - name : Checkout
21+ uses : actions/checkout@v4
22+
23+ - name : Set up Node
24+ uses : actions/setup-node@v4
25+ with :
26+ node-version : 22
27+ cache : npm
28+
29+ - name : Install deps
30+ run : npm ci
31+
32+ - name : Build
33+ run : npm run build
34+
35+ - name : Log in to GHCR
36+ uses : docker/login-action@v3
37+ with :
38+ registry : ${{ env.REGISTRY }}
39+ username : ${{ github.repository_owner }}
40+ password : ${{ secrets.GITHUB_TOKEN }}
41+
42+ - name : Extract metadata (tags, labels)
43+ id : meta
44+ uses : docker/metadata-action@v5
45+ with :
46+ images : |
47+ ${{ env.REGISTRY }}/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}
48+ tags : |
49+ type=raw,value=latest
50+ type=sha
51+
52+ - name : Build and push image
53+ uses : docker/build-push-action@v6
54+ with :
55+ context : .
56+ push : true
57+ tags : ${{ steps.meta.outputs.tags }}
58+ labels : ${{ steps.meta.outputs.labels }}
59+
Original file line number Diff line number Diff line change 22
33Tiny Next.js “hello” container for smoke tests and IaC placeholders.
44
5- ![ Screenshot] ( /screenshot.png )
5+ ![ Screenshot] ( /public/ screenshot.png )
66
77- Big ` hello 👋 ` in the center
88- Light/dark toggle
You can’t perform that action at this time.
0 commit comments