Files
vildhjarta/Dockerfile
T
Fredrik Johansson 1cf768183d
Docker / build-and-push (push) Successful in 1m17s
Add Docker deployment, matching Djupet's setup
Multi-stage build (node build -> nginx:alpine serve), docker-compose
with a configurable HOST_PORT (default 47174, an unusual port left
free for nginx proxy manager to front later), and a Gitea Actions
workflow that builds/pushes the image on push to main.

Verified: image builds, container serves the app and all art assets
on port 47174.
2026-08-09 21:55:04 +02:00

12 lines
232 B
Docker

FROM node:22-alpine AS build
WORKDIR /app
COPY package.json ./
RUN npm install
COPY . .
RUN npm run build
FROM nginx:alpine
COPY --from=build /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80