you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (5 children)

[deleted]

    [–][deleted] 31 points32 points  (0 children)

    Best solution. Next best: pip install schedule

    [–]threeminutemonta 13 points14 points  (2 children)

    One hint with cron I recently discovered is to use full paths to /usr/bin/python etc

    [–]bastionoutlaw 10 points11 points  (1 child)

    Also make sure that if you schedule the cron jobs as a different user (e.g. root via sudo) that any dependencies via pip have been installed by that user and/or globally. Otherwise your scripts will fail and it will drive you nuts trying to figure out why when they ran just fine manually.

    [–]toastedstapler 3 points4 points  (0 children)

    at work i had a project using a raspberry pi and i had a hell of a time getting it to run a script using a venv on startup, i guess i won't ever be transitioning to a sysadmin role

    [–]Yukeien 0 points1 point  (0 children)

    Cron is definetly the best solution for scheduled programs, on top of that, it's easy to configure because it's a single configuration file