ychappyboy commited on
Commit
ae99937
·
1 Parent(s): 3a316a3

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +14 -3
Dockerfile CHANGED
@@ -1,8 +1,19 @@
1
  FROM node:18
 
 
2
  RUN git clone https://github.com/Hk-Gosuto/ChatGPT-Next-Web-LangChain.git
 
 
3
  WORKDIR "ChatGPT-Next-Web-LangChain"
 
 
4
  ENV NEXT_PUBLIC_ENABLE_NODEJS_PLUGIN=1
5
- RUN npm i
6
- RUN npm run build
 
 
 
7
  EXPOSE 3000
8
- CMD ["npm", "run", "start"]
 
 
 
1
  FROM node:18
2
+
3
+ # 克隆项目仓库
4
  RUN git clone https://github.com/Hk-Gosuto/ChatGPT-Next-Web-LangChain.git
5
+
6
+ # 设置工作目录
7
  WORKDIR "ChatGPT-Next-Web-LangChain"
8
+
9
+ # 设置环境变量
10
  ENV NEXT_PUBLIC_ENABLE_NODEJS_PLUGIN=1
11
+
12
+ # 安装依赖并构建项目
13
+ RUN yarn install && yarn build
14
+
15
+ # 暴露端口
16
  EXPOSE 3000
17
+
18
+ # 启动命令
19
+ CMD yarn start