Does Heroku support a per‑dyno time zone setting for platform‑generated logs and scheduler events?
0 reputation · 20 Jan 2022, 01:27 UTC
Goal
Determine whether the Heroku platform provides a built‑in mechanism to assign a regional time zone to individual dynos so that timestamps in platform‑emitted data such as logs, metrics, and scheduler runs reflect that zone instead of UTC.
Constraints and uncertainty
Heroku dynos run with the system clock set to UTC and the platform does not apply a regional offset by default. Timestamp handling is delegated to the application, which must store dates in UTC and perform any user‑local conversion in code. There is no documented feature that automatically converts platform logs or scheduler timestamps based on a dyno‑level TZ environment variable, and it is unclear whether setting TZ affects those platform‑generated timestamps.
Specific questions:
- Does setting a TZ config var on a Heroku app change the time zone used for logs, metrics, and scheduler event timestamps?
- If not, what is the recommended approach for applications that need region‑specific timestamps in platform‑generated output without modifying each log line?