# Use the official Node.js image | |
FROM node:latest | |
# Set the working directory inside the container | |
WORKDIR /aatsan/my-App | |
# Clone the GitHub repository | |
RUN apt-get update && apt-get install -y git && \ | |
git clone https://github.com/Emmraan/api-crud-ops.git -b fronted-view . && \ | |
rm -rf /var/lib/apt/lists/* | |
# Copy the repository content to the working directory | |
COPY . . | |
# Install Node.js dependencies | |
RUN npm install | |
# Expose the application port | |
EXPOSE 3000 | |
# Start the application | |
CMD ["npm", "start"] | |