From 553dfaced3019912b68b630c9413a2e576766f41 Mon Sep 17 00:00:00 2001 From: redxef Date: Fri, 24 Feb 2023 01:39:16 +0100 Subject: [PATCH] Only restart upon close_wrie or modify. --- start-nginx.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/start-nginx.sh b/start-nginx.sh index a809886..98fca02 100755 --- a/start-nginx.sh +++ b/start-nginx.sh @@ -38,7 +38,7 @@ run_nginx() { run_inotifywait() { while find "$dstdir" -type f -exec \ sed -En '/ssl_certificate/ s/^\s*ssl_certificate(_key)? (.*);.*$/\2/p' {} \; | sort | uniq | \ - inotifywait --fromfile=-; do + inotifywait --fromfile=- -e close_write -e modify; do nginx -s reload done }