clone3 commited on
Commit
9651cde
1 Parent(s): 8ac92c7

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +15 -9
Dockerfile CHANGED
@@ -1,14 +1,20 @@
1
- # Use Node.js v12 as the base image
2
- FROM node:12-alpine
3
 
4
- # Set the working directory inside the container
5
  WORKDIR /app
6
 
7
- # Install an older version of commander and web-terminal globally
8
- RUN npm install -g [email protected] web-terminal
9
 
10
- # Expose the port on which web-terminal will run
11
- EXPOSE 8088
12
 
13
- # Define the default command to run web-terminal on port 8088
14
- CMD ["web-terminal", "--port", "8088"]
 
 
 
 
 
 
 
1
+ # Use an official Node.js runtime as a parent image
2
+ FROM node:18
3
 
4
+ # Set the working directory in the container
5
  WORKDIR /app
6
 
7
+ # Copy the package.json and package-lock.json files
8
+ COPY package*.json ./
9
 
10
+ # Install the Node.js dependencies
11
+ RUN npm install
12
 
13
+ # Copy the rest of the application code
14
+ COPY . .
15
+
16
+ # Expose the WebSocket port
17
+ EXPOSE 6060
18
+
19
+ # Start the backend server
20
+ CMD ["node", "server.js"]