# ---------------------------------------------------------------------------- # jb-website — static build served by Caddy with automatic HTTPS. # Multi-stage: node builds Astro, alpine Caddy serves the result. # ---------------------------------------------------------------------------- # ---- build stage ------------------------------------------------------------ FROM node:24-alpine AS build WORKDIR /app # Install deps separately so they cache between source-only changes. COPY package.json package-lock.json* ./ RUN npm ci COPY . . RUN npm run build # ---- runtime stage ---------------------------------------------------------- FROM caddy:2-alpine COPY Caddyfile /etc/caddy/Caddyfile COPY --from=build /app/dist /srv # Internal plaintext server only — the edge reverse proxy terminates TLS and # forwards to this port. No 443 here. EXPOSE 80