From 197cd684c03a1829fd6b62a9a0710d92c4a5b771 Mon Sep 17 00:00:00 2001 From: redxef Date: Sat, 19 Aug 2023 01:51:29 +0200 Subject: [PATCH] List monitored files. --- start-nginx.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/start-nginx.sh b/start-nginx.sh index 98fca02..2fabf15 100755 --- a/start-nginx.sh +++ b/start-nginx.sh @@ -37,7 +37,8 @@ run_nginx() { run_inotifywait() { while find "$dstdir" -type f -exec \ - sed -En '/ssl_certificate/ s/^\s*ssl_certificate(_key)? (.*);.*$/\2/p' {} \; | sort | uniq | \ + echo 'Monitoring the following files for changes:' + sed -En '/ssl_certificate/ s/^\s*ssl_certificate(_key)? (.*);.*$/\2/p' {} \; | sort | uniq | tee /dev/stderr \ inotifywait --fromfile=- -e close_write -e modify; do nginx -s reload done