Skip to content

Commit

Permalink
add docker file
Browse files Browse the repository at this point in the history
  • Loading branch information
agarwalhimanshugaya committed Jul 3, 2024
1 parent 30cd798 commit f698c26
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Use the official Nginx image from the Docker Hub
FROM nginx:latest

# Remove the default Nginx website
RUN rm -rf /usr/share/nginx/html/*

# Copy the current directory contents into the Nginx web directory
COPY . /usr/share/nginx/html

# Expose port 80 to the outside world
EXPOSE 80

# Run Nginx in the foreground (this ensures the container stays running)
CMD ["nginx", "-g", "daemon off;"]

#run this app you have to use 2 command
# 1. docker build -t your-image-name
# 2. docker run -d -p 3000:80 your-image-name

0 comments on commit f698c26

Please sign in to comment.