Download scripts/entrypoint.sh from aanycmn/momo: direct link, hf CLI and curl.
- Browser
- Download file 867 Bytes
-
https://huggingface.co/spaces/aanycmn/momo/resolve/main/scripts/entrypoint.sh
- Command line
-
hf download hf://spaces/aanycmn/momo/scripts/entrypoint.sh
-
curl -L -o entrypoint.sh https://huggingface.co/spaces/aanycmn/momo/resolve/main/scripts/entrypoint.sh
867 Bytes
| # 程序入口脚本 | |
| # 该脚本将作为Docker容器的入口点 | |
| #开启定时任务,暂时取消备份任务,备份的话就一定要停止运行才能保证数据库完整,但是那样没什么意义了 | |
| # cron | |
| echo -e "======================启动nginx========================\n" | |
| nginx -s reload 2>/dev/null || nginx -c /etc/nginx/nginx.conf | |
| echo -e "nginx启动成功...\n" | |
| cd /app/src | |
| if [ -n "$WEBPASSWORD" ]; then | |
| sed -i 's/web_password:[[:space:]]*admin/web_password: '"$WEBPASSWORD"'/' config.example.yaml | |
| fi | |
| if [ -n "$RABBITMQ_URL" ]; then | |
| sed -i '' '1i import bootstrap' wfxl_openai_regst.py | |
| fi | |
| pm2 start wfxl_openai_regst.py --name "openai-cpa" --interpreter python3 --watch --ignore-watch="data/* logs/*" --log-date-format="YYYY-MM-DD HH:mm:ss" --output /app/logs/pm2-out.log --error /app/logs/pm2-err.log | |
| tail -f /dev/null |