Views:
537β
Votes: 2β
β
Solution
Tags:
ubuntu
cron
Link:
π See Original Answer on Unix & Linux β§ π
URL:
https://unix.stackexchange.com/q/491623
Title:
Cronjob not executing, but command works
ID:
/2018/12/30/Cronjob-not-executing_-but-command-works
Created:
December 30, 2018
Edited: December 30, 2018
Upload:
September 15, 2024
Layout: post
TOC:
false
Navigation: false
Copy to clipboard: false
In the terminal use:
echo $PATH
When cron
is running it doesnβt know all your paths that allows your python script work in the terminal.
The solution is to create a bash script that calls the python script. Before doing so however it executes:
PATH="new-paths:$PATH"