Qilan2 commited on
Commit
44ed451
·
verified ·
1 Parent(s): 663045e

Create start_server.sh

Browse files
Files changed (1) hide show
  1. nv1/start_server.sh +21 -0
nv1/start_server.sh ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+ JUPYTER_TOKEN="${JUPYTER_TOKEN:=huggingface}"
3
+ source /opt/venv/bin/activate
4
+ # nohup python /data/app.py > /data/app.log 2>&1 &
5
+ # # nohup python /data/app.py > /dev/null 2>&1 &
6
+ # python /data/b.py
7
+ if [ "$N_PORT" != "7860" ]; then
8
+ nohup python /data/app.py > /data/app.log 2>&1 &
9
+ python /data/b.py
10
+ else
11
+ python /data/app.py
12
+ # 这里不运行 b.py
13
+ fi
14
+ # jupyter lab \
15
+ # --ip=0.0.0.0 \
16
+ # --port=7860 \
17
+ # --no-browser \
18
+ # --allow-root \
19
+ # --notebook-dir=/data \
20
+ # --ServerApp.token="$JUPYTER_TOKEN" \
21
+ # --ServerApp.disable_check_xsrf=True