Changed daily script to master.conf variables

This commit is contained in:
2026-04-05 06:13:05 +00:00
parent 0248fbb283
commit 1376bf3411
4 changed files with 81 additions and 115 deletions
-24
View File
@@ -191,30 +191,6 @@ start_containers() {
done
}
# -----------------------------------------------------------------------------------------------
# RSYNC SLOT LIMITER
# -----------------------------------------------------------------------------------------------
wait_for_rsync() {
: "${RETRY_COUNT:=5}"
: "${MAX_RSYNC_PROCS:=2}"
: "${SLEEP:=2}"
for i in $(seq 1 "$RETRY_COUNT"); do
COUNT=$(ps -eo cmd | grep "[r]sync .*${REMOTE_SERVER}" | wc -l || true)
if [[ "$COUNT" -ge "$MAX_RSYNC_PROCS" ]]; then
warn "$ICON_RETRY Waiting for rsync slot ($COUNT/$MAX_RSYNC_PROCS) — attempt $i/$RETRY_COUNT"
sleep "$SLEEP"
else
log "Rsync slot available ($COUNT/$MAX_RSYNC_PROCS)"
return 0
fi
done
error "Too many rsync processes after $RETRY_COUNT attempts, aborting."
exit 1
}
# -----------------------------------------------------------------------------------------------
# RSYNC OPTIONS
# -----------------------------------------------------------------------------------------------