Spaces:
Sleeping
Sleeping
# Use Node.js image | |
FROM node:18-alpine | |
# Set working directory | |
WORKDIR /app | |
# Copy package.json and install dependencies using Yarn | |
COPY package.json yarn.lock ./ | |
RUN yarn install --frozen-lockfile | |
# Copy project files | |
COPY . . | |
RUN mkdir -p /app/public && chown -R node:node /app/public | |
# Expose the port | |
EXPOSE 5000 | |
# Start the backend server | |
CMD ["yarn", "start"] | |