n8n GENERIC_TIMEZONE environment value not applying correctly

By default n8n uses America/New York timezone, this is used by scheduling nodes and also shows as the selected timezone in each workflows settings: "Default:America/New York" is what is says. To change this you set the required timezone as an environment variable. This should get teh schedule/cron nodes running atthe correct time, change the default workflow timezone etc. I have tried every variation I can think of but cannot get it to apply correctly when running n8n in tipi. I have set it these ways: - directly in the docker-compose.yml for n8n-1 - as a reference in the yml to the app.env - using a user-config yml and app.env both coded directly into the yml or again referencing the .env It appears the timezone is applying for the schedule nodes and when using now() it is returning in the correct timezone. But the workflow time default value will not change, which makes me quesiton where else it is not applying. I have a post on n8n community running as well to see if I can get any input there - https://community.n8n.io/t/timezone-setting-doesnt-take-effect/63400
n8n Community
Timezone setting doesn't take effect
Describe the problem/error/question I am trying to get n8n setup in runtipi, adding the GENERIC_TIMEZONE= to the environment part of the docker compose file. Have tried 3 different zones, Australia/Melbourne, Australia/Sydney and just for laughs a random one in America. The issue stays the same, in settings for a workflow the timezone still just...
28 Replies
Meisner
MeisnerOP4w ago
i forgot to mention that I am restarting the app after any changes and have also tried reseting the app.
InfBoumcyCastle
user-config is the way to go. Can you show us your created files ?
GENERIC_TIMEZONE=${TZ}
GENERIC_TIMEZONE=${TZ}
Would be my try in user-config .this is only the specific line, not the complete compose, since I am on mobile This should apply the tz from tipi
Meisner
MeisnerOP4w ago
services: n8n-1: environment: - GENERIC_TIMEZONE=${GENERIC_TIMEZONE} that is the full docker compose in user config n8n-1 folder. and i have added a sperate app.env with the required value labelled as GENERIC_TIMEZONE and also tried adding it to the main env file. i will try referencing the eixstint TZ value now lol the "-" changed to a dot point ok tested using tz reference instead. no change. thank you for the suggestion though. as i mentioned for most things it seems to be applying so i might just get over it and manually set the part that isn't applying in each workflow i just get fixated when something doesn't do what it is meant to and i cant figure out why
InfBoumcyCastle
i will test as well for science 🙂
Meisner
MeisnerOP4w ago
that would be awesome.. i would love it to be something i have done wrong. this is my first time setting up runtipi and i am also not super well versed in docker... but i did extensive reading and my expertise and work is in tech so i am pretty confident i did it all correctly.. but i have banged my head againts this partiuclar wall to exhaustion prior to posting.. im out of ideas with the knowledge i have.
InfBoumcyCastle
user-config docker-compose.yml: runtipi/user-config/n8n-1/docker-compose.yml
services:
n8n-1:
environment:
- GENERIC_TIMEZONE=${TZ}
services:
n8n-1:
environment:
- GENERIC_TIMEZONE=${TZ}
docker inspect:
"Env": [
...
"GENERIC_TIMEZONE=Europe/Amsterdam",
...
],
"Env": [
...
"GENERIC_TIMEZONE=Europe/Amsterdam",
...
],
the tz seems to be in the container. where do see that n8n did not adapt the tz?
InfBoumcyCastle
in the app i created a test schedule trigger
No description
InfBoumcyCastle
this shows the correct time for me
Meisner
MeisnerOP4w ago
Go into a workflow and click the three dots up top right and click settings
InfBoumcyCastle
i see.
Meisner
MeisnerOP4w ago
Yep
InfBoumcyCastle
but maybe this is not a setting coming from the env var?
Meisner
MeisnerOP4w ago
In my cloudron hosted instance of n8n that I am replacing when I change the environment timezone it changes that value in the workflow settings page
InfBoumcyCastle
Set the self-hosted instance timezone | n8n Docs
Change the default timezone for your self-hosted n8n instance.
Meisner
MeisnerOP4w ago
Sorry didn't quite follow that?
InfBoumcyCastle
the n8n doc says the tz from the env should be used in a workflow as default, which is not what is happening brb 10 min
Meisner
MeisnerOP4w ago
No worries. I'm actually about to head to sleep seeing as it's midnight here. Tomorrow I will spin up an empty VM and just install docker and test it in there... It could be a bug with the docker version of n8n and nothing to do with tipi's wrapper I was hoping to get some traction on my post over on n8n forum but nothing so far Anyway if you figure anything g out or need any info or tests done by me just post em here and I will check in the morning. I appreciate you checking it out. P.s if we get this working do you know how I submit a change suggestion to have the n8n default docker compose include the reference to the tipi timezone?
InfBoumcyCastle
i think i got it
services:
n8n-1:
image: n8nio/n8n:1.70.1
environment:
- GENERIC_TIMEZONE=${TZ}
services:
n8n-1:
image: n8nio/n8n:1.70.1
environment:
- GENERIC_TIMEZONE=${TZ}
i used the current official image - i suppose there was a bug. @Stavros @Nicolas is there a reason n8n has no updates for a while now?
Stavros
Stavros4w ago
Yeahhhhh It's because of renovate updating the deprecated version @Nicolas I don't remember how the logic works with deprecated. If we bump the tipi version while an app is deprecated will it show as an update?
Nicolas
Nicolas4w ago
Yes it because renovate tries to update both at the same time And we don't want to update the deprecated one
Meisner
MeisnerOP4w ago
Well this has quickly gone beyond my knowledge. Can I just manually maintain which version I'm using my specifying it as @InfBoumcyCastle did above and just changing the version number when I want to upgrade?
InfBoumcyCastle
Just use my docker compose from above with the image
Meisner
MeisnerOP4w ago
Yea I can do that, but I'm just thinking ahead for when n8n gets more updates, do I just change that number and restart?
InfBoumcyCastle
Normally apps in the app store get updates automatically. So in case n8n gets an update then you remove the image line
Meisner
MeisnerOP4w ago
Ok I can do that. And if it doesn't get an update and I want to manually update I can just specify the newer version? Is there any value in me trying to understand above what was meant as the reason it wasn't getting updates? Thanks again for working it out and for the help
InfBoumcyCastle
- yes - not necessarily
Meisner
MeisnerOP4w ago
Perfect, works for me. appreciate it
Want results from more Discord servers?
Add your server