feat: initial project scaffold
- React 19 + Vite + TailwindCSS frontend - Express + TypeScript backend API - PostgreSQL schema and migrations - Docker Compose orchestration - Drone CI/CD pipeline - Pages: Dashboard, Servers, Containers, Services, Logs, Metrics, Settings
This commit is contained in:
22
backend/Dockerfile
Normal file
22
backend/Dockerfile
Normal file
@@ -0,0 +1,22 @@
|
||||
FROM node:20-alpine AS base
|
||||
WORKDIR /app
|
||||
COPY package*.json ./
|
||||
|
||||
FROM base AS deps
|
||||
RUN npm ci --only=production
|
||||
|
||||
FROM base AS builder
|
||||
RUN npm ci
|
||||
COPY . .
|
||||
RUN npm run build
|
||||
|
||||
FROM node:20-alpine AS runner
|
||||
WORKDIR /app
|
||||
ENV NODE_ENV=production
|
||||
RUN addgroup --system --gid 1001 nodejs && adduser --system --uid 1001 appuser
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY --from=builder /app/dist ./dist
|
||||
COPY package.json ./
|
||||
USER appuser
|
||||
EXPOSE 3001
|
||||
CMD ["node", "dist/index.js"]
|
||||
Reference in New Issue
Block a user