feat(init): add initial project scaffolding and database schema
- Add Dockerfile for multi-stage production build - Add Drizzle configuration and initial migration for PostgreSQL schema - Add project configuration files (.prettierrc, .prettierignore, .dockerignore) - Define core database tables: assets, memberships, site_settings
This commit is contained in:
+27
@@ -0,0 +1,27 @@
|
||||
# ---- Build Stage ----
|
||||
FROM node:22-alpine AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package.json package-lock.json ./
|
||||
RUN npm ci --ignore-scripts
|
||||
|
||||
COPY . .
|
||||
|
||||
RUN npm run build
|
||||
|
||||
# ---- Production Stage ----
|
||||
FROM node:22-alpine AS runner
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY --from=builder /app/package.json /app/package-lock.json ./
|
||||
COPY --from=builder /app/build ./build
|
||||
COPY --from=builder /app/node_modules ./node_modules
|
||||
|
||||
ENV NODE_ENV=production
|
||||
ENV PORT=3000
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
CMD ["node", "build/index.js"]
|
||||
Reference in New Issue
Block a user