Hello,
On a Debian host, I need to run a Python script through cron. The script will need to write a file elsewhere on the disk.
I have the following questions:
1. Will it run as root or as the script owner?
2. What access rights (chmod) should I use?
3. Do I need to set the shebang line? #!/usr/bin/python
4. In the cron file (crontab -e) , do I need to use absolute paths for both the interpreter and the script, eg. /usr/bin/python /home/joe/script.py
5. In case it doesn't work as expected, does cron write a log file somewhere?
Thank you.
On a Debian host, I need to run a Python script through cron. The script will need to write a file elsewhere on the disk.
I have the following questions:
1. Will it run as root or as the script owner?
2. What access rights (chmod) should I use?
3. Do I need to set the shebang line? #!/usr/bin/python
4. In the cron file (crontab -e) , do I need to use absolute paths for both the interpreter and the script, eg. /usr/bin/python /home/joe/script.py
5. In case it doesn't work as expected, does cron write a log file somewhere?
Thank you.