File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -67,6 +67,9 @@ RUN npm install
6767# Runtime stage
6868FROM registry.cn-qingdao.aliyuncs.com/dataease/sqlbot-python-pg:latest
6969
70+ RUN apt-get update && apt-get install -y --no-install-recommends supervisor \
71+ && rm -rf /var/lib/apt/lists/*
72+
7073RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
7174 echo "Asia/Shanghai" > /etc/timezone
7275
@@ -85,11 +88,12 @@ COPY start.sh /opt/sqlbot/app/start.sh
8588COPY g2-ssr/*.ttf /usr/share/fonts/truetype/liberation/
8689COPY --from=sqlbot-builder ${SQLBOT_HOME} ${SQLBOT_HOME}
8790COPY --from=ssr-builder /app /opt/sqlbot/g2-ssr
91+ COPY g2-ssr/supervisord.conf /etc/supervisor/conf.d/g2-ssr.conf
8892COPY --from=vector-model /opt/maxkb/app/model /opt/sqlbot/models
8993
9094WORKDIR ${SQLBOT_HOME}/app
9195
92- RUN mkdir -p /opt/sqlbot/images /opt/sqlbot/g2-ssr
96+ RUN mkdir -p /opt/sqlbot/images /opt/sqlbot/g2-ssr/logs
9397
9498EXPOSE 3000 8000 8001 5432
9599
Load diff This file was deleted.
Original file line number Diff line number Diff line change 88 "@rollup/plugin-json" : " ^6.1.0" ,
99 "lodash" : " ^4.17.21" ,
1010 "nan" : " ^2.22.2" ,
11- "pm2" : " ^6.0.13" ,
1211 "node-canvas" : " ^2.9.0" ,
1312 "nprogress" : " ^0.2.0"
1413 },
Original file line number Diff line number Diff line change 1+ [program:g2-ssr]
2+ command=node /opt/sqlbot/g2-ssr/app.js
3+ directory=/opt/sqlbot/g2-ssr
4+ autostart=true
5+ autorestart=true
6+ startsecs=1
7+ startretries=10
8+ redirect_stderr=true
9+ stdout_logfile=/opt/sqlbot/g2-ssr/logs/supervisor_stdout.log
10+ stderr_logfile=/opt/sqlbot/g2-ssr/logs/supervisor_stderr.log
11+ stopasgroup=true
Original file line number Diff line number Diff line change 11SSR_PATH=/opt/sqlbot/g2-ssr
22APP_PATH=/opt/sqlbot/app
3- PM2_CMD_PATH=$SSR_PATH /node_modules/pm2/bin/pm2
43
54/usr/local/bin/docker-entrypoint.sh postgres &
65sleep 5
76wait-for-it 127.0.0.1:5432 --timeout=120 --strict -- echo -e " \033[1;32mPostgreSQL started.\033[0m"
87
9- nohup $PM2_CMD_PATH start $SSR_PATH /app.js &
10- # nohup node $SSR_PATH/app.js &
8+ nohup /usr/bin/supervisord -c /etc/supervisor/supervisord.conf &
119
1210nohup uvicorn main:mcp_app --host 0.0.0.0 --port 8001 --proxy-headers --forwarded-allow-ips=' *' &
1311
You can’t perform that action at this time.
0 commit comments