lesaff / serverpilot-letsencrypt

(NO LONGER MAINTAINED) | Bash script to generate and install Let's Encrypt certificate for your websites on your ServerPilot account (Free or Paid Plan)
MIT License
346 stars 84 forks source link

--quiet in cron #81

Closed gstrainovic closed 5 years ago

gstrainovic commented 5 years ago

/usr/bin/letsencrypt renew && service nginx-sp reload in cron as root on Ubuntu 18.04 works, but I recive all 12h email. I want only recive a email if is fail. I try with /usr/bin/letsencrypt renew --quiet && service nginx-sp reload and i recive a email with the message /bin/sh: 1: service: not found. In bash shell works with --quiet. What am I doing wrong?

gstrainovic commented 5 years ago

Works with 0 */12 * * * /usr/bin/letsencrypt renew --quiet && /usr/sbin/service nginx-sp reload