Update Dockerfile

This commit is contained in:
2025-10-27 22:19:38 +00:00
parent 5741c7089a
commit 3d2661c5be

View File

@@ -5,8 +5,8 @@ WORKDIR /app
# Copy package files # Copy package files
COPY package*.json ./ COPY package*.json ./
# Install dependencies # Install ALL dependencies (including dev dependencies for build)
RUN npm ci RUN npm ci --include=dev
# Copy source code # Copy source code
COPY . . COPY . .
@@ -14,8 +14,11 @@ COPY . .
# Build TypeScript # Build TypeScript
RUN npm run build RUN npm run build
# Remove source files to reduce image size (optional) # Verify dist was created
# RUN rm -rf src tsconfig.json RUN ls -la dist/ || (echo "ERROR: dist not created!" && exit 1)
# Clean up dev dependencies to reduce image size (optional)
RUN npm prune --omit=dev
# Start the app # Start the app
CMD ["npm", "start"] CMD ["npm", "start"]