[#19] alert和web增加系统集成测试
This commit is contained in:
@@ -3,13 +3,13 @@ set -euo pipefail
|
||||
|
||||
URL="http://127.0.0.1:80"
|
||||
|
||||
echo "[INFO] Starting frontend health check loop for $URL..."
|
||||
echo "[INFO] Starting Argus web health check loop for $URL..."
|
||||
|
||||
while true; do
|
||||
if curl -s --max-time 5 "$URL" > /dev/null; then
|
||||
echo "[OK] $(date '+%Y-%m-%d %H:%M:%S') Frontend is healthy"
|
||||
echo "[OK] $(date '+%Y-%m-%d %H:%M:%S') Argus web is healthy"
|
||||
else
|
||||
echo "[ERROR] $(date '+%Y-%m-%d %H:%M:%S') Frontend health check failed"
|
||||
echo "[ERROR] $(date '+%Y-%m-%d %H:%M:%S') Argus web health check failed"
|
||||
exit 1
|
||||
fi
|
||||
sleep 10
|
||||
|
||||
@@ -7,8 +7,8 @@ user=root
|
||||
[program:web]
|
||||
command=/usr/local/bin/start-web-supervised.sh
|
||||
user=root
|
||||
stdout_logfile=/var/log/supervisor/web.log
|
||||
stderr_logfile=/var/log/supervisor/web_error.log
|
||||
stdout_logfile=/var/log/supervisor/web-frontend.log
|
||||
stderr_logfile=/var/log/supervisor/web-frontend_error.log
|
||||
autorestart=true
|
||||
startretries=3
|
||||
startsecs=5
|
||||
@@ -28,6 +28,18 @@ stopwaitsecs=10
|
||||
killasgroup=true
|
||||
stopasgroup=true
|
||||
|
||||
[program:dns-monitor]
|
||||
command=/usr/local/bin/dns-monitor.sh
|
||||
user=root
|
||||
stdout_logfile=/var/log/supervisor/dns-monitor.log
|
||||
stderr_logfile=/var/log/supervisor/dns-monitor_error.log
|
||||
autorestart=true
|
||||
startretries=3
|
||||
startsecs=5
|
||||
stopwaitsecs=10
|
||||
killasgroup=true
|
||||
stopasgroup=true
|
||||
|
||||
[unix_http_server]
|
||||
file=/var/run/supervisor.sock
|
||||
chmod=0700
|
||||
|
||||
Reference in New Issue
Block a user