Add Dockerfile, nginx config, and Gitea Actions CI workflow
Multi-stage Docker build produces an Nginx container serving the static SPA. The CI workflow runs pnpm check on every push and builds/pushes a Docker image on semver tags. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
19
Dockerfile
Normal file
19
Dockerfile
Normal file
@@ -0,0 +1,19 @@
|
||||
FROM node:22-slim AS build
|
||||
ENV PNPM_HOME="/pnpm"
|
||||
ENV PATH="$PNPM_HOME:$PATH"
|
||||
RUN corepack enable
|
||||
|
||||
WORKDIR /app
|
||||
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml ./
|
||||
COPY packages/domain/package.json packages/domain/
|
||||
COPY packages/application/package.json packages/application/
|
||||
COPY apps/web/package.json apps/web/
|
||||
RUN pnpm install --frozen-lockfile
|
||||
|
||||
COPY . .
|
||||
RUN pnpm --filter web build
|
||||
|
||||
FROM nginx:alpine
|
||||
COPY --from=build /app/apps/web/dist /usr/share/nginx/html
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
EXPOSE 80
|
||||
Reference in New Issue
Block a user