From a3b58d25ff01ed4758edc976035706fe0bd15c77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C4=93teris=20Caune?= Date: Mon, 15 Jun 2020 16:14:03 +0300 Subject: [PATCH] Change "--output" to "-o" in curl examples. --- templates/docs/monitoring_cron_jobs.html | 17 +++++++++-------- templates/docs/monitoring_cron_jobs.md | 15 ++++++++------- templates/front/snippets/crontab.html | 2 +- templates/front/snippets/crontab.txt | 2 +- 4 files changed, 19 insertions(+), 17 deletions(-) diff --git a/templates/docs/monitoring_cron_jobs.html b/templates/docs/monitoring_cron_jobs.html index e20f8e75..c2051859 100644 --- a/templates/docs/monitoring_cron_jobs.html +++ b/templates/docs/monitoring_cron_jobs.html @@ -42,7 +42,7 @@ increasingly important as you add more checks to your account.

after the command:

$ crontab -e
 # m h dom mon dow command
-  8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 --output /dev/null PING_URL
+  8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 -o /dev/null PING_URL
 
@@ -73,11 +73,12 @@ there is an error. Feel free to adjust the curl options to suit your needs.

-s, --silent - Silent or quiet mode. Don't show progress meter or error messages. + Silent or quiet mode. Use it to hide progress meter, + but it also hides error messages. -S, --show-error - When used with -s it makes curl show error message if it fails. + Re-enables error messages when -s is used. --retry <num> @@ -85,14 +86,14 @@ there is an error. Feel free to adjust the curl options to suit your needs.

If a transient error is returned when curl tries to perform a transfer, it will retry this number of times before giving up. Setting the number to 0 makes curl do no retries - (which is the default). Transient error means either: a timeout, - an FTP 4xx response code or an HTTP 5xx response code. + (which is the default). Transient error is a timeout or an HTTP 5xx + response code. - > /dev/null + -o /dev/null - Redirect curl's stdout to /dev/null (error messages go to stderr,) + Redirect curl's stdout to /dev/null (error messages still go to stderr) @@ -109,4 +110,4 @@ there is an error. Feel free to adjust the curl options to suit your needs.

System clock synchronized: yes NTP service: active RTC in local TZ: no - + \ No newline at end of file diff --git a/templates/docs/monitoring_cron_jobs.md b/templates/docs/monitoring_cron_jobs.md index f1b4b050..7cf3ae18 100644 --- a/templates/docs/monitoring_cron_jobs.md +++ b/templates/docs/monitoring_cron_jobs.md @@ -41,7 +41,7 @@ after the command: ```bash $ crontab -e # m h dom mon dow command - 8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 --output /dev/null PING_URL + 8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 -o /dev/null PING_URL ``` Now, each time your cron job runs, it will send a HTTP request to the ping URL. @@ -74,11 +74,12 @@ there is an error. Feel free to adjust the curl options to suit your needs. -s, --silent - Silent or quiet mode. Don't show progress meter or error messages. + Silent or quiet mode. Use it to hide progress meter, + but it also hides error messages. -S, --show-error - When used with -s it makes curl show error message if it fails. + Re-enables error messages when -s is used. --retry <num> @@ -86,14 +87,14 @@ there is an error. Feel free to adjust the curl options to suit your needs. If a transient error is returned when curl tries to perform a transfer, it will retry this number of times before giving up. Setting the number to 0 makes curl do no retries - (which is the default). Transient error means either: a timeout, - an FTP 4xx response code or an HTTP 5xx response code. + (which is the default). Transient error is a timeout or an HTTP 5xx + response code. - > /dev/null + -o /dev/null - Redirect curl's stdout to /dev/null (error messages go to stderr,) + Redirect curl's stdout to /dev/null (error messages still go to stderr) diff --git a/templates/front/snippets/crontab.html b/templates/front/snippets/crontab.html index 1ea0fcd7..8937fb9b 100644 --- a/templates/front/snippets/crontab.html +++ b/templates/front/snippets/crontab.html @@ -1,3 +1,3 @@
# m h dom mon dow command
-  8 6 *   *   *   /home/user/backup.sh && curl -fsS --retry 3 --output /dev/null {{ ping_url }}
+  8 6 *   *   *   /home/user/backup.sh && curl -fsS --retry 3 -o /dev/null {{ ping_url }}
 
diff --git a/templates/front/snippets/crontab.txt b/templates/front/snippets/crontab.txt index 84edb987..1db344f6 100644 --- a/templates/front/snippets/crontab.txt +++ b/templates/front/snippets/crontab.txt @@ -1,2 +1,2 @@ # m h dom mon dow command - 8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 --output /dev/null PING_URL + 8 6 * * * /home/user/backup.sh && curl -fsS --retry 3 -o /dev/null PING_URL