File tree Expand file tree Collapse file tree 3 files changed +12
-7
lines changed
Expand file tree Collapse file tree 3 files changed +12
-7
lines changed Original file line number Diff line number Diff line change 11:3000 {
22 respond /healthz 200
3- handle_path /blog* {
3+ redir /blog /blog/ 308
4+ handle /blog* {
45 reverse_proxy blog:3000
56 }
67 handle {
Original file line number Diff line number Diff line change @@ -3,10 +3,12 @@ This repo is a Next.js app used to generate a static site. The final production
33## Development (local only)
44- Install deps: ` npm install `
55- Run dev server: ` npm run dev ` then open http://localhost:3000
6+ > ⚠️ These steps are purely for local development; the production image ships only static assets and never contains a Node/npm runtime.
67
78## Build (production image)
89- ` docker build -t www-website . `
910- Runtime is static files only; mount/serve with RO filesystem (e.g., ` docker run --read-only --tmpfs /tmp --tmpfs /config --tmpfs /data -p 3000:3000 www-website ` ).
11+ > ⚠️ The final container maps only the generated ` out ` directory and static assets; keep it read-only and do not run any Node/npm scripts there.
1012
1113## Deployment notes
1214- Published image: ` ghcr.io/devsh-graphics-programming/www-website ` (tags: ` latest ` , ` master ` , ` sha-* ` ).
Original file line number Diff line number Diff line change @@ -4,18 +4,20 @@ services:
44 image : devsh-website
55 read_only : true
66 tmpfs :
7- - /tmp
8- - /config
9- - /data
7+ - /tmp:size=32m
8+ - /config:size=32m
9+ - /data:size=32m
1010 restart : unless-stopped
1111
1212 blog :
1313 image : ${BLOG_IMAGE:-ghcr.io/devsh-graphics-programming/www-blog:latest}
14+ ports :
15+ - " 3001:3000"
1416 read_only : true
1517 tmpfs :
16- - /tmp
17- - /config
18- - /data
18+ - /tmp:size=32m
19+ - /config:size=16m
20+ - /data:size=16m
1921 restart : unless-stopped
2022
2123 proxy :
You can’t perform that action at this time.
0 commit comments