Update Dockerfile
Browse files- Dockerfile +18 -0
Dockerfile
CHANGED
@@ -1 +1,19 @@
|
|
|
|
1 |
FROM node
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
#Use the official Node.js image.
|
2 |
FROM node
|
3 |
+
# Set the working directory.
|
4 |
+
WORKDIR /usr/src/app
|
5 |
+
|
6 |
+
# Copy package.json and package-lock.json.
|
7 |
+
COPY package*.json ./
|
8 |
+
|
9 |
+
# Install dependencies.
|
10 |
+
RUN npm install express body-parser
|
11 |
+
|
12 |
+
# Copy the rest of the application code.
|
13 |
+
COPY . .
|
14 |
+
|
15 |
+
# Expose the port the app runs on.
|
16 |
+
EXPOSE 3000
|
17 |
+
|
18 |
+
# Command to run the app.
|
19 |
+
CMD ["node", "app.js"]
|