Clear stale runner logs before starting ATVM watcher
- update the watcher start helper to remove the old /tmp/<build-name>.log file before starting a fresh watcher instance for a reused build name - prevent the watcher from inheriting stale started_at timestamps from previous runs with the same build name and immediately exiting as HUNG - make reused-build watcher startup safer by resetting both watcher state and the matching temporary runner log
This commit is contained in:
@@ -49,8 +49,10 @@ if [[ -z "$BUILD_NAME" ]]; then
|
||||
fi
|
||||
|
||||
RUN_DIR="${STATE_ROOT}/${BUILD_NAME}"
|
||||
RUN_LOG="/tmp/${BUILD_NAME}.log"
|
||||
systemctl stop "atvm-run-watcher@${BUILD_NAME}.service" >/dev/null 2>&1 || true
|
||||
rm -rf "$RUN_DIR"
|
||||
rm -f "$RUN_LOG"
|
||||
mkdir -p "$RUN_DIR"
|
||||
|
||||
cat >"${RUN_DIR}/watch.env" <<EOF
|
||||
|
||||
Reference in New Issue
Block a user