How to prevent cron from emailing protected directory pw
We have cron run scripts that are in some protected directories (htaccess basic auth). When cron sends out the email for these jobs it also sends out the PW and username since it has to be included in the curl command. Is there a way to prevent this or do I need to silence cron to dev null and just write my own email results (which is too bad because I like to see all of the cron stats).
Thanks!
-
Hello, Are you able to run the script directly instead of using cURL to access the script (e.g. "php /path/to/file.php")? If so, you should be able to skip the authentication requirement. Thank you. 0 -
Thank you, that should work. Last time we tried running php (vs curl) from cPanel cron they never ran. No clue why. These run from bash just fine so I'll give it a go. Thanks again! 0 -
Seems to work fine, but (of course) no longer can I get stats from curl. Oh well. Good enough! Thanks again! 0
Please sign in to leave a comment.
Comments
3 comments