Setting default timezone for glitch server

Hi,

May i ask how to set the default timezone for my project? i tried go to terminal and set the timezone using tzselect but it seems to reset itself after sometime. Any solution to this? Thank you!

You won’t be able to set the timezone permanently, because the server is restarted after it’s inactive for a while. It’s probably best to pass times from the server to the client in UTC, and then use the timezone on the client to display them to the user.

What exactly are you trying to do with dates/times?

You could set the default timezone you want in Moment Timezone https://momentjs.com/timezone/ on the server.

1 Like

My server should be always on since there are always activity. However, the node-scheduler seems to not happy with tzselect and it is always triggered at UTC time instead of my local time.

For scheduled tasks there are plenty of web cron services online. Just expose a route to trigger your task.

Seems to me I should have some way to get all my logs showing local time and not zulu time. Sure, Linux servers and Unix servers have always had the date/time in zulu but allowed for per user fixes.

Just my two cents worth.