Files
ebook/Dockerfile
koziavin 5c7e5fabbb
Some checks failed
Deploy Application / deploy (push) Failing after 7m8s
first commit
2025-06-11 21:01:17 +04:00

30 lines
503 B
Docker

# Build stage
FROM node:20-alpine as build
WORKDIR /app
# Copy package files
COPY package.json yarn.lock ./
# Install dependencies
RUN yarn install --frozen-lockfile
# Copy source code
COPY . .
# Build the application
RUN yarn build
# Production stage
FROM nginx:alpine
# Copy built assets from build stage
COPY --from=build /app/dist /usr/share/nginx/html
# Copy nginx configuration
COPY nginx.conf /etc/nginx/conf.d/default.conf
# Expose port 80
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]