diff --git a/Dockerfile b/Dockerfile index 6057a56..1a9aea5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,8 +5,8 @@ WORKDIR /app # Copy package files COPY package*.json ./ -# Install dependencies -RUN npm ci +# Install ALL dependencies (including dev dependencies for build) +RUN npm ci --include=dev # Copy source code COPY . . @@ -14,8 +14,11 @@ COPY . . # Build TypeScript RUN npm run build -# Remove source files to reduce image size (optional) -# RUN rm -rf src tsconfig.json +# Verify dist was created +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 CMD ["npm", "start"] \ No newline at end of file