From b0fa292ed03645633b2505142fd3c71883bc2b81 Mon Sep 17 00:00:00 2001 From: Riccardo Pittau Date: Tue, 4 Feb 2025 15:29:05 +0100 Subject: [PATCH] Fix runlogwatch failure if LOG_DIR does not exist --- scripts/runlogwatch.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/runlogwatch.sh b/scripts/runlogwatch.sh index fe48de0dc..40f9d5f80 100755 --- a/scripts/runlogwatch.sh +++ b/scripts/runlogwatch.sh @@ -3,6 +3,8 @@ # Ramdisk logs path LOG_DIR="/shared/log/ironic/deploy" +mkdir -p "${LOG_DIR}" + python3 -m pyinotify -e IN_CLOSE_WRITE -v "${LOG_DIR}" | while read -r path _action file; do echo "************ Contents of ${path}/${file} ramdisk log file bundle **************"