I have a scheduled task which fetches and runs the cf-nginx-ip-passthrough (cf.sh) script periodically. It seems to fail at random, disabling the cloudflare.conf file and touching cf-stop. I believe this is caused by an occasional network hiccup but I can't be sure, and it highlights three problems:
- The script always returns
0 so the Plesk setting to notify on error doesn't work.
- If I enable notifications for every run, the emails only contain the cURL output and
Configuration applied. Restarting Nginx. On and after the fatal failure, I only receive the cURL output in the emails, so I can't be certain what going wrong.
- Oddly, the
.disabled file is always valid when I log in to intervene (I rename it back to cloudflare.conf and nginx -t succeeds), so I wonder if the code to rollback to the previous working config is broken.
I have a scheduled task which fetches and runs the cf-nginx-ip-passthrough (
cf.sh) script periodically. It seems to fail at random, disabling thecloudflare.conffile and touchingcf-stop. I believe this is caused by an occasional network hiccup but I can't be sure, and it highlights three problems:0so the Plesk setting to notify on error doesn't work.Configuration applied. Restarting Nginx.On and after the fatal failure, I only receive the cURL output in the emails, so I can't be certain what going wrong..disabledfile is always valid when I log in to intervene (I rename it back tocloudflare.confandnginx -tsucceeds), so I wonder if the code to rollback to the previous working config is broken.