NeoPy commited on
Commit
3b18d92
·
verified ·
1 Parent(s): b9ee0e6

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +19 -0
Dockerfile ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM node:20-alpine
2
+ USER root
3
+
4
+ USER 1000
5
+ WORKDIR /usr/src/app
6
+ # Copy package.json and package-lock.json to the container
7
+ COPY --chown=1000 package.json package-lock.json ./
8
+
9
+ # Copy the rest of the application files to the container
10
+ COPY --chown=1000 . .
11
+
12
+ RUN npm install
13
+ RUN npm run build
14
+
15
+ # Expose the application port (assuming your app runs on port 3000)
16
+ EXPOSE 3000
17
+
18
+ # Start the application
19
+ CMD ["npm", "start"]