Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


    Cloudron Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    n8n timezone? logs retention?

    N8N
    4
    16
    381
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • potemkin_ai
      potemkin_ai last edited by

      Hello! n8n reads from Docker environment 3 key values:

      1. timezone
      2. key to encrypt all of the credentials
      3. retention logs policy

      From what I can see, since my credentials survive n8n instance restart, item number 2 seems to be good, but since my cron node seems to be executing at the wrong time, the time zone is not - could you please, check / fix that?

      And one more thing - what is the logs retention policy? How many hours of logs are kept?

      Thank you! And special thanks for adding n8n to the apps!

      girish 1 Reply Last reply Reply Quote 1
      • girish
        girish Staff @potemkin_ai last edited by

        @potemkin_ai looks like you can set GENERIC_TIMEZONE as suggested by https://docs.n8n.io/getting-started/installation/docker-quickstart.html#setting-timezone . On Cloudron, you can edit /app/data/env using the file manager and restart the app.

        potemkin_ai 1 Reply Last reply Reply Quote 0
        • Moved from Support by  girish girish 
        • girish
          girish Staff last edited by

          I put a note in https://docs.cloudron.io/apps/n8n/#timezone

          1 Reply Last reply Reply Quote 1
          • girish
            girish Staff last edited by

            As for the logs, we keep last 10MB of logs per app.

            1 Reply Last reply Reply Quote 0
            • potemkin_ai
              potemkin_ai @girish last edited by

              @girish thank you!

              Is there a way for Cloudron to pick up for that purpose a Time Zone that I'm configuring at the settings page?

              girish 1 Reply Last reply Reply Quote 1
              • girish
                girish Staff @potemkin_ai last edited by

                @potemkin_ai Currently, no, but I think that's a good idea worth investigating!

                potemkin_ai 1 Reply Last reply Reply Quote 1
                • potemkin_ai
                  potemkin_ai @girish last edited by

                  @girish thanks, yes, that would be very nice, if n8n container's time zone (and probably other services) would be regulated that way.

                  As for the logs - I realized that we might speak about different kind of logs here - n8n stores execution logs, that might fill up the disk very quickly: https://community.n8n.io/t/hard-disk-full-where-to-delete-logs/2298

                  Here are the environment variables that seems like of the most importance at n8n:

                  GENERIC_TIMEZONE=
                  WEBHOOK_TUNNEL_URL=https://FQDN/ #this one, to make sure webhook URL will work fine
                  N8N_ENCRYPTION_KEY=.. #to avoid loosing credentials on docker restart
                  
                  #clear execution logs
                  EXECUTIONS_DATA_PRUNE=true
                  EXECUTIONS_DATA_MAX_AGE=672
                  
                  girish 1 Reply Last reply Reply Quote 1
                  • girish
                    girish Staff @potemkin_ai last edited by

                    @potemkin_ai ah, i see. Do you think the defaults you have provided are reasonable? If so, I can put them as part of the default install.

                    potemkin_ai 1 Reply Last reply Reply Quote 0
                    • potemkin_ai
                      potemkin_ai @girish last edited by

                      @girish absolutely!

                      It makes n8n to perform in right timezone, have proper webhook URL, keep credentials (not loosing then during the docker rebuild), avoid disk overflow from the executions log.

                      1 Reply Last reply Reply Quote 2
                      • girish
                        girish Staff last edited by

                        OK, I have put this as the default for new installations.

                        potemkin_ai 1 Reply Last reply Reply Quote 1
                        • potemkin_ai
                          potemkin_ai @girish last edited by

                          @girish lovely, thank you!

                          1 Reply Last reply Reply Quote 0
                          • andreasdueren
                            andreasdueren last edited by

                            @potemkin_ai I’m struggling to get the time zone set up. Do you have any suggestions as to what I did wrong? These are my env settings:

                            Set the logging level to 'debug'
                            export EXECUTIONS_DATA_SAVE_MANUAL_EXECUTIONS=true
                            export EXECUTIONS_DATA_SAVE_ON_ERROR=all
                            export EXECUTIONS_DATA_SAVE_ON_SUCCESS=all
                            export N8N_LOG_LEVEL=info
                            
                            GENERIC_TIMEZONE='Europe/Berlin'
                            TZ='Europe/Berlin'
                            WEBHOOK_TUNNEL_URL=https://top.level.domain/
                            N8N_ENCRYPTION_KEY='redacted'
                            
                            
                            EXECUTIONS_DATA_PRUNE=true
                            EXECUTIONS_DATA_MAX_AGE=672
                            
                            girish 1 Reply Last reply Reply Quote 1
                            • girish
                              girish Staff @andreasdueren last edited by

                              @andreasdueren you have to add export in front of each line

                              andreasdueren 1 Reply Last reply Reply Quote 3
                              • andreasdueren
                                andreasdueren @girish last edited by

                                @girish duh that’s probably why 😄

                                humptydumpty 1 Reply Last reply Reply Quote 0
                                • humptydumpty
                                  humptydumpty @andreasdueren last edited by

                                  @andreasdueren I'm glad I found this post. At least you had the = in there. Stupid me typed it in like this: GENERIC_TIMEZONE America/Chicago and was wondering why the app crashed 🤦

                                  andreasdueren 1 Reply Last reply Reply Quote 1
                                  • andreasdueren
                                    andreasdueren @humptydumpty last edited by

                                    @humptydumpty 😄

                                    1 Reply Last reply Reply Quote 0
                                    • First post
                                      Last post
                                    Powered by NodeBB