feat(m1-1): scaffold SvelteKit + Dockerfile + TDD test harness
- SvelteKit (JS, adapter-node) home page + /api/health route - frontend/Dockerfile multi-stage build->serve (slabuploader-m1:local, 349MB) - Test harness: Vitest unit + Playwright e2e; smoke tests RED->GREEN verified - Build, image build, and image serve all verified
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
# SlabUploader M1 — frontend only (no FastAPI/Woo). Multi-stage: build then serve.
|
||||
FROM node:22-alpine AS build
|
||||
WORKDIR /app
|
||||
COPY package*.json ./
|
||||
RUN npm install
|
||||
COPY . .
|
||||
RUN npm run build
|
||||
|
||||
FROM node:22-alpine AS run
|
||||
WORKDIR /app
|
||||
ENV NODE_ENV=production
|
||||
COPY package*.json ./
|
||||
RUN npm install --omit=dev
|
||||
COPY --from=build /app/build ./build
|
||||
COPY --from=build /app/node_modules ./node_modules
|
||||
EXPOSE 80
|
||||
ENV PORT=80
|
||||
CMD ["node", "build/index.js"]
|
||||
Reference in New Issue
Block a user