It is always a struggle configuring a cronjob to run certain scripts; there is always a mis configuration, a PATH, an environment variable that is different from when you use it in interactive mode, etc… Do you have any tricks to avoid or minimize those issues?

cc @selfhost@lemmy.ml

  • SokathHisEyesOpen@lemmy.ml
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Put all the logic in a php file and just configure crontab to run the file at the given interval and output the results to a log file. Use crontab.guru to help with scheduling.