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

    Solved How to stop Roundcube session ending when I close my laptop lid?

    Roundcube
    8
    39
    1050
    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.
    • necrevistonnezr
      necrevistonnezr @jdaviescoates last edited by

      @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

      Sigh. The state of open source webmail is so abysmal 😢 (I wonder if SnappyMail have fixed this annoying issue...)

      I agree. BTW Snappymail is a fork of Rainloop, not of Roundcube.

      jdaviescoates 1 Reply Last reply Reply Quote 3
      • jdaviescoates
        jdaviescoates @necrevistonnezr last edited by

        @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

        BTW Snappymail is a fork of Rainloop, not of Roundcube.

        Oh yes, thanks for the reminder

        I use Cloudron with Gandi & Hetzner

        1 Reply Last reply Reply Quote 0
        • jdaviescoates
          jdaviescoates @jdaviescoates last edited by jdaviescoates

          @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

          @necrevistonnezr thanks, I'll give that a try in the first instance and see how I get on...

          So, I added:

          $rcmail_config['session lifetime‘] = 10080;
          

          To app/data/customconfig.php

          But it hasn't made any difference at all.

          When I opened my laptop this morning I had to log back in to Roundcube, again.

          Now I'm wondering if I restarted the app (or whether I would've needed to)

          I use Cloudron with Gandi & Hetzner

          fbartels 1 Reply Last reply Reply Quote 0
          • fbartels
            fbartels App Dev @jdaviescoates last edited by

            @jdaviescoates since this is just php code a restart is not needed. What is needed however is you reloading the application in your browser to make the change reach your session.

            @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

            Gmail doesn't do this

            Gmail is also not a php application. The reason sessions are handled better there is because their user sessions are based on openid connect, which means you get a refresh token with every login, that can (as long as the refresh token is valid) be used to get a session token without the need to perform another login.

            jdaviescoates 1 Reply Last reply Reply Quote 1
            • jdaviescoates
              jdaviescoates @fbartels last edited by

              @fbartels said in How to stop Roundcube session ending when I close my laptop lid?:

              What is needed however is you reloading the application in your browser to make the change reach your session.

              Thanks. I guess it refreshed when I logged in again this morning. Let's see what happens tomorrow morning...

              I use Cloudron with Gandi & Hetzner

              jdaviescoates 1 Reply Last reply Reply Quote 0
              • jdaviescoates
                jdaviescoates @jdaviescoates last edited by

                @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                Let's see what happens tomorrow morning...

                No change.

                Screenshot from 2022-04-14 10-03-45.png

                I use Cloudron with Gandi & Hetzner

                necrevistonnezr 1 Reply Last reply Reply Quote 0
                • necrevistonnezr
                  necrevistonnezr @jdaviescoates last edited by

                  @jdaviescoates is uBlock Origin blocking any cookies?

                  jdaviescoates 1 Reply Last reply Reply Quote 1
                  • jdaviescoates
                    jdaviescoates @necrevistonnezr last edited by

                    @necrevistonnezr hah, thanks!

                    That's quite likely it I guess.

                    Thought I'd turned uBlock off for all my own domain but I've moved this Roundcube install around a bit so I guess not!

                    Have turned it off now, hopefully that'll help...

                    I use Cloudron with Gandi & Hetzner

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

                      @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                      $rcmail_config['session lifetime‘] = 10080;

                      If I'm not mistaken, there's a typo in that code. After LIFETIME, the ending ' seems to be something else.

                      jdaviescoates necrevistonnezr 2 Replies Last reply Reply Quote 0
                      • jdaviescoates
                        jdaviescoates @humptydumpty last edited by

                        @humptydumpty yeah, when I pasted it in to the terminal it was clear (because of the code highlight) it wasn't correct so I replaced it with a ' - but thanks for pointing that out in case that was the issue 🙂

                        I use Cloudron with Gandi & Hetzner

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

                          @humptydumpty said in How to stop Roundcube session ending when I close my laptop lid?:

                          @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                          $rcmail_config['session lifetime‘] = 10080;

                          If I'm not mistaken, there's a typo in that code. After LIFETIME, the ending ' seems to be something else.

                          You‘re right! I had fiddled with that post on the iPhone - quite a hassle. I corrected it now in the post above for future reference.

                          1 Reply Last reply Reply Quote 1
                          • timconsidine
                            timconsidine App Dev @jdaviescoates last edited by

                            @jdaviescoates I realise this is not the direction of most replies/solutions, but if the programmatic approach does not deliver, on my Mac I have a utility which responds to triggers like laptop shut and fires off an action. I'm sure Windows has similar. Although the execution action may be a bit brutal (close app).

                            Just a thought.

                            jdaviescoates 1 Reply Last reply Reply Quote 2
                            • jdaviescoates
                              jdaviescoates @timconsidine last edited by

                              @timconsidine thanks. I'm on Ubuntu, but probably stuff on here too I could try if my turning off uBlock doesn't help...

                              I use Cloudron with Gandi & Hetzner

                              jdaviescoates 1 Reply Last reply Reply Quote 1
                              • jdaviescoates
                                jdaviescoates @jdaviescoates last edited by

                                @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                if my turning off uBlock doesn't help...

                                Well, turning off uBlock Origin and Privacy Badger hasn't helped at all.

                                I posted an issue on the Roundcube github too and they've just replied saying "this is not supported" and closed it 😞

                                https://github.com/roundcube/roundcubemail/issues/8504

                                So perhaps I'm trying to achieve something which isn't possible yet 😞

                                Sigh. The state of open source webmail is so abysmal is makes me sad.

                                I use Cloudron with Gandi & Hetzner

                                necrevistonnezr 1 Reply Last reply Reply Quote 1
                                • necrevistonnezr
                                  necrevistonnezr @jdaviescoates last edited by necrevistonnezr

                                  @jdaviescoates Yeah, Alexander is not very helpful - though you gave him a location for the config that is non-standard and Cloudron specific (/app/data/ something).
                                  Again, I use Roundcube everyday on my work computer and the session is kept alive even between reboots with the config described above...
                                  Is it browser related (is it Firefox?) - maybe try a different one? A setting that deletes cookies from time to time?

                                  1 Reply Last reply Reply Quote 3
                                  • A
                                    alexlixs @jdaviescoates last edited by girish

                                    @jdaviescoates Facing same issue.

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

                                      @alexlixs Can you confirm you are not a bot?

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

                                        I just played around with this again and this seems to be working for me:

                                        $config['session lifetime'] = '10080';

                                        It's unclear if $rcconfig or just $config should be used or if either would work, but the latter, i.e. just $config, appears to be working for me.

                                        Also in previous attempts I was missing the 's around the 10080, and from the formatting of other settings in the customconfig.php I figured I'd try '10080' and then it worked.

                                        I use Cloudron with Gandi & Hetzner

                                        girish jdaviescoates 2 Replies Last reply Reply Quote 1
                                        • Topic has been marked as a question  jdaviescoates jdaviescoates 
                                        • Topic has been marked as solved  jdaviescoates jdaviescoates 
                                        • girish
                                          girish Staff @jdaviescoates last edited by

                                          @jdaviescoates $config is the correct variable name.

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

                                            @girish said in How to stop Roundcube session ending when I close my laptop lid?:

                                            @jdaviescoates $config is the correct variable name.

                                            Well, for some values, it seems that $rcmail_config is correct…

                                            As said before, for me

                                            $rcmail_config['session_lifetime'] = 10080;
                                            

                                            works?!

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

                                              @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                              Well, for some values, it seems that $rcmail_config is correct…

                                              I just looked up roundcube code and it seems $rcmail_config and $config are just aliases. https://github.com/roundcube/roundcubemail/blob/01b7dbd1a75bd712f4cac69f5aa421b049dd5d8b/program/include/rcmail_install.php#L159 says $rcmail_config is the deprecated name.

                                              1 Reply Last reply Reply Quote 2
                                              • Topic is now a regular thread  jdaviescoates jdaviescoates 
                                              • jdaviescoates
                                                jdaviescoates @jdaviescoates last edited by

                                                @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                                I just played around with this again and this seems to be working for me:

                                                $config['session lifetime'] = '10080';

                                                It's unclear if $rcconfig or just $config should be used or if either would work, but the latter, i.e. just $config, appears to be working for me.

                                                Also in previous attempts I was missing the 's around the 10080, and from the formatting of other settings in the customconfig.php I figured I'd try '10080' and then it worked.

                                                This was previously marked as the solution, but that hasn't done it either. Think I'm gonna have to give up on this one 😞

                                                @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                                Sigh. The state of open source webmail is so abysmal

                                                You can say that again! Recent updates to Roundcube have broken logging in without an error and the CalDAV connection. 😢

                                                I use Cloudron with Gandi & Hetzner

                                                necrevistonnezr 1 Reply Last reply Reply Quote 0
                                                • necrevistonnezr
                                                  necrevistonnezr @jdaviescoates last edited by

                                                  @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                                  You can say that again! Recent updates to Roundcube have broken logging in without an error and the CalDAV connection. 😢

                                                  I have neither of these issues on current Roundcube with Safari or Edge. No errors logging in and I’m staying logged in. What browser are you using?

                                                  jdaviescoates 1 Reply Last reply Reply Quote 1
                                                  • jdaviescoates
                                                    jdaviescoates @necrevistonnezr last edited by

                                                    @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                    What browser are you using?

                                                    Firefox. But pretty sure I've tested in Chromium before too.

                                                    The other issues have been resolved by updated the CalDAV plugin but I still get logged out of email whenever I close my laptop lid.

                                                    I use Cloudron with Gandi & Hetzner

                                                    necrevistonnezr 1 Reply Last reply Reply Quote 0
                                                    • necrevistonnezr
                                                      necrevistonnezr @jdaviescoates last edited by

                                                      @jdaviescoates Sorry, but Firefox is not what it used to be (or the web has changed) - I gave up on Firefox due to so many sites not loading, not being compatible or other issues. Might be their strict default privacy and container settings.

                                                      1 Reply Last reply Reply Quote 3
                                                      • Topic has been marked as a question  jdaviescoates jdaviescoates 
                                                      • jdaviescoates
                                                        jdaviescoates last edited by

                                                        @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                        @jdaviescoates Sorry, but Firefox is not what it used to be (or the web has changed) - I gave up on Firefox due to so many sites not loading, not being compatible or other issues. Might be their strict default privacy and container settings.

                                                        That's it! (I think)

                                                        I just clicked on the little shield on the far left of the address bar and toggled Enhanced Tracking Protection is ON for this site to Enhance Tracking Protection is OFF for this site

                                                        Screenshot from 2022-08-09 23-02-48.png

                                                        Then I closed down Firefox and all my other apps and restarted my machine. Open up Firefox and I'm still logged in. Hopefully it'll now stay that way!

                                                        Thanks!

                                                        I use Cloudron with Gandi & Hetzner

                                                        jdaviescoates 1 Reply Last reply Reply Quote 5
                                                        • Topic has been marked as solved  jdaviescoates jdaviescoates 
                                                        • jdaviescoates
                                                          jdaviescoates @jdaviescoates last edited by

                                                          @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                                          Hopefully it'll now stay that way!

                                                          It hasn't 😞

                                                          But it's still WAY better than it was before.

                                                          I use Cloudron with Gandi & Hetzner

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

                                                            @jdaviescoates I added the url to the exception rules in FF (privacy & security section) and that didn't help either. I tried using Brave instead, no luck with that either.

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

                                                              @humptydumpty yeah, I'm now leaning towards giving up on Roundcube and moving to SnappyMail instead as that doesn't seem to have this problem (and is nice and snappy too! and the CardDAV integration stuff is out of the box instead of having to install a plugin for Roundcube)

                                                              I use Cloudron with Gandi & Hetzner

                                                              humptydumpty necrevistonnezr 2 Replies Last reply Reply Quote 1
                                                              • humptydumpty
                                                                humptydumpty @jdaviescoates last edited by

                                                                @jdaviescoates I might end up doing the same 🙂

                                                                1 Reply Last reply Reply Quote 1
                                                                • necrevistonnezr
                                                                  necrevistonnezr @jdaviescoates last edited by

                                                                  @jdaviescoates I always come back to Roundcube as Snappymail does not do full text search and hence is useless for me. Also sender aliases are much easier to set up in Roundcube.

                                                                  robi 1 Reply Last reply Reply Quote 1
                                                                  • robi
                                                                    robi @necrevistonnezr last edited by

                                                                    @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                    Also sender aliases are much easier to set up in Roundcube.

                                                                    Eh? It's easy as pie in Snappy.. just add another identity fill in two fields and done.

                                                                    Life of Advanced Technology

                                                                    necrevistonnezr 2 Replies Last reply Reply Quote 1
                                                                    • necrevistonnezr
                                                                      necrevistonnezr @robi last edited by necrevistonnezr

                                                                      This post is deleted!
                                                                      1 Reply Last reply Reply Quote 0
                                                                      • necrevistonnezr
                                                                        necrevistonnezr @robi last edited by necrevistonnezr

                                                                        @robi said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                        @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                        Also sender aliases are much easier to set up in Roundcube.

                                                                        Eh? It's easy as pie in Snappy.. just add another identity fill in two fields and done.

                                                                        True, I remembered that wrong. Though you cannot use a different domain / SMTP server, I believe.

                                                                        And to clarify regarding full text search: You can search for message content, but not across folders(!).

                                                                        See also https://forum.cloudron.io/topic/6391/virtual-all-mails-folder-in-dovecot-to-improve-search/

                                                                        jdaviescoates 1 Reply Last reply Reply Quote 1
                                                                        • jdaviescoates
                                                                          jdaviescoates @necrevistonnezr last edited by

                                                                          @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                          cannot use a different domain

                                                                          You can. Right now I've got both uniteddiversity.coop and bettermedia.uk addresses set-up in Snappy (but yeah, both domains are connected to the same Cloudron)

                                                                          @necrevistonnezr said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                          You can search for message content, but not across folders(!).

                                                                          Yeah, I've noticed that, a bit of pain. Think perhaps I'll create an issue on SnappyMail github about it...

                                                                          I use Cloudron with Gandi & Hetzner

                                                                          necrevistonnezr 1 Reply Last reply Reply Quote 0
                                                                          • necrevistonnezr
                                                                            necrevistonnezr @jdaviescoates last edited by necrevistonnezr

                                                                            @jdaviescoates said in How to stop Roundcube session ending when I close my laptop lid?:

                                                                            Yeah, I've noticed that, a bit of pain. Think perhaps I'll create an issue on SnappyMail github about it...

                                                                            I did already some time ago: https://github.com/the-djmaze/snappymail/issues/196 (was linked above)
                                                                            For that we need the Dovecot Virtual Folder @girish mentioned in the other thread

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