Files
RepoDructor/Dockerfile
josedario87 f0ed200577
Some checks failed
build-and-deploy / build (push) Failing after 25s
build-and-deploy / deploy (push) Has been skipped
Add Docker deployment configuration and CI/CD pipeline
2025-08-04 13:51:09 -06:00

33 lines
538 B
Docker

# Build stage
FROM node:18-alpine AS builder
WORKDIR /app
# Copy package files
COPY package*.json ./
# Install dependencies
RUN npm ci --only=production
# Copy source code
COPY . .
# Build the application
RUN npm run build
# Production stage
FROM node:18-alpine AS production
WORKDIR /app
# Copy built application from builder stage
COPY --from=builder /app/.output ./
# Create music directory for volume mounting
RUN mkdir -p /app/public/music
# Expose port
EXPOSE 3000
# Start the application
CMD ["node", "server/index.mjs"]