Skip to content

Setting timezone for periodic task #1472

@dreackm

Description

@dreackm

I have a periodic task that's supposed to run every 10 seconds of every weekday from 8 am to 5pm. Its cron expression is thus : * 8-17 * * 1-5 */10. I did'nt realize until today that this will run in UTC while I am in Africa/Blantyre (which is 2 hours ahead). To run it in the time I expect, I am simply specifying the hour segment as UTC, i.e., 6-15.

With the native crontab, I could specify which timezone a particular entry should run in with CRON_TZ environment variable. How do I do something similar in this case?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions