Skip to content

Commit

Permalink
chore: Update Dockerfile to use Node.js 14 runtime and install depend…
Browse files Browse the repository at this point in the history
…encies
  • Loading branch information
manthanank committed Jun 6, 2024
1 parent 443af81 commit b6939a8
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,20 @@
FROM alpine:3.17.2
CMD ["echo", "Hello World!"]
# Use an official Node.js runtime as the base image
FROM node:14

# Set the working directory in the container to /app
WORKDIR /app

# Copy package.json and package-lock.json into the working directory
COPY package*.json ./

# Install any needed packages specified in package.json
RUN npm install

# Bundle the app source inside the Docker image
COPY . .

# Make port 3000 available to the world outside the Docker container
EXPOSE 3000

# Define the command to run the app
CMD [ "node", "index.js" ]

0 comments on commit b6939a8

Please sign in to comment.