Mercurial Hosting > luan
view host/stop.sh @ 2136:3ca8f933209d nginx_decoupled
Initial; use ~/.nginx-luan/ as nginx master conf dir instead of trying to detect the system default.
| author | Violet7 |
|---|---|
| date | Mon, 19 Jan 2026 19:47:11 -0800 |
| parents | 6a2383baecb6 |
| children |
line wrap: on
line source
#!/bin/bash . check_app.sh; #seconds to wait toWait=30; i=0; getPids; if [ "$PIDS" != "" ]; then while [ $i -lt $toWait ]; do kill -TERM $PIDS; sleep 1; getPids; if [ "$PIDS" == "" ]; then break fi; let i=$i+1; done; if [ "$PIDS" != "" ]; then echo "Can't stop app in ${i} seconds"; exit 0; else rm started.lock; echo "App stopped"; fi; else echo "no running app found"; fi; ./stop_nginx.sh; exit 0;
