更新 scripts/deploy_gpu_monitor.sh

This commit is contained in:
joy 2025-09-10 14:52:44 +08:00
parent 4586e980b9
commit 27ba57ad6e
1 changed files with 1 additions and 1 deletions

View File

@ -67,7 +67,7 @@ restart_node_exporter() {
# 安全添加定时任务(避免重复) # 安全添加定时任务(避免重复)
add_cron_job() { add_cron_job() {
local cron_line="${CRON_SCHEDULE} ${TARGET_SCRIPT} >> ${LOG_FILE} 2>&1" local cron_line="${CRON_SCHEDULE} bash ${TARGET_SCRIPT} >> ${LOG_FILE} 2>&1"
# 检查任务是否已存在(精确匹配) # 检查任务是否已存在(精确匹配)
if crontab -l 2>/dev/null | grep -qxF "${cron_line}"; then if crontab -l 2>/dev/null | grep -qxF "${cron_line}"; then