docs4you commited on
Commit
2e406d1
·
verified ·
1 Parent(s): 6b1ce2d

Upload Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +20 -0
Dockerfile ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the official Node.js 18 image as a base
2
+ FROM node:18-alpine
3
+
4
+ # Set the working directory in the container
5
+ WORKDIR /usr/src/app
6
+
7
+ # Copy the package.json and package-lock.json files (if any)
8
+ COPY package*.json ./
9
+
10
+ # Install any dependencies (if there are any, otherwise this step is skipped)
11
+ RUN npm install --only=production
12
+
13
+ # Copy the rest of the application code to the working directory
14
+ COPY . .
15
+
16
+ # Expose the port that the server listens on
17
+ EXPOSE 4123
18
+
19
+ # Command to run the application
20
+ CMD ["node", "index.js"]