Skip to content

Instantly share code, notes, and snippets.

@Vikash-8090-Yadav
Created June 7, 2023 09:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Vikash-8090-Yadav/9fa89073c340ffc6e6b01417b2424da1 to your computer and use it in GitHub Desktop.
Save Vikash-8090-Yadav/9fa89073c340ffc6e6b01417b2424da1 to your computer and use it in GitHub Desktop.
# Use an official Node.js runtime as a parent image
FROM node:14
# Set the working directory to /app
WORKDIR /app
# Copy package.json and package-lock.json to the container
COPY package*.json ./
# Install dependencies
RUN npm install
# Copy the rest of the application code to the container
COPY . .
# Build the Next.js application
RUN npm run build
# Expose port 3000
EXPOSE 3000
# Start the application
CMD ["npm", "run" ,"dev"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment