Migrate perilous to ubuntu-prod
Some checks failed
Deploy Stacks / deploy-prod (push) Failing after 1s
Deploy Stacks / deploy-dev (push) Has been cancelled

- Update traefik route to use Docker container names instead of host IPs
- Update Dockerfile to build full app with sharp, ejs, marked dependencies
- Simplify docker-compose.yml (remove traefik labels, use file provider routing)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-21 15:38:14 -05:00
parent cb9a8fa46b
commit db0745e57d
3 changed files with 7 additions and 15 deletions

View File

@@ -1,7 +1,7 @@
FROM node:18-alpine FROM node:18-alpine
RUN apk add --no-cache python3 make g++ vips-dev
WORKDIR /usr/src/app WORKDIR /usr/src/app
COPY package.json ./ COPY content/package.json ./
RUN npm install RUN npm install
COPY server.js ./
EXPOSE 3000 EXPOSE 3000
CMD ["node", "server.js"] CMD ["node", "content/server.js"]

View File

@@ -7,11 +7,8 @@ services:
- "3003:3000" - "3003:3000"
volumes: volumes:
- ./content:/usr/src/app/content - ./content:/usr/src/app/content
labels: environment:
- "traefik.enable=true" - EMAIL_PASSWORD=${PERILOUS_CODE_SERVER_PASSWORD}
- "traefik.http.routers.perilous-secure.entrypoints=https,http"
- "traefik.http.routers.perilous-secure.rule=Host(`chapel.perilous.dev`,`forest.perilous.dev`,`castle.perilous.dev`,`siege.perilous.dev`,`pass.perilous.dev`,`perilous.dev`,`www.perilous.dev`,`word.perilous.dev`,`mirror.perilous.dev`,`request.perilous.dev`,`the.chapel.perilous.dev`,`the.forest.perilous.dev`,`the.castle.perilous.dev`,`the.siege.perilous.dev`,`the.pass.perilous.dev`,`the.word.perilous.dev`,`the.mirror.perilous.dev`,`the.request.perilous.dev`,`the.adventure.perilous.dev`,`the.cs.perilous.dev`,`the.gallery.perilous.dev`,`gallery.perilous.dev`,`the.perilous.dev`,`ring.perilous.dev`,`the.ring.perilous.dev`,`autumn.perilous.dev`,`the.autumn.perilous.dev`)"
- "traefik.http.routers.perilous-secure.tls.certresolver=http"
networks: networks:
- web - web
@@ -30,11 +27,6 @@ services:
- PGID=1000 - PGID=1000
- PROXY_DOMAIN=cs.perilous.dev - PROXY_DOMAIN=cs.perilous.dev
- DEFAULT_WORKSPACE=/home/project - DEFAULT_WORKSPACE=/home/project
labels:
- "traefik.enable=true"
- "traefik.http.routers.pcs-secure.entrypoints=https,http"
- "traefik.http.routers.pcs-secure.rule=Host(`cs.perilous.dev`)"
- "traefik.http.routers.pcs-secure.tls.certresolver=http"
networks: networks:
- web - web

View File

@@ -20,9 +20,9 @@ http:
perilous: perilous:
loadBalancer: loadBalancer:
servers: servers:
- url: "http://192.168.5.34:3003" - url: "http://perilous-web:3000"
perilous-cs: perilous-cs:
loadBalancer: loadBalancer:
servers: servers:
- url: "http://192.168.5.34:8180" - url: "http://perilous-code-server:8443"