It would only require to re-login this frequently if you restart the server. You can try persisted sessions if you really need to restart server regularly.
How do I turn on persisted sessions? I can't find anything in the config file documentation for that. Last night I logged in and this morning it asked for my password again, and I know I didn't restart the server overnight.
Oh sweet. Just added that into my config file and sessions do persist across restarts now. Will report back if I open the app or the site after a few hours and it asks for my password again.
Unfortunately it still times out too fast. I just opened the manager app and was greeted with the login screen.
Android or iOS? What version of the OS and the app and other details?
Traccar Manager 3.1 on iOS 15.6.1. Server is running the 5.3 docker image. I also just uninstalled and reinstalled the app to see if that would fix it.
For iOS we will have touch id / face id support starting from next release.
Would I still be able to stay logged in if I choose not to use face/touch ID?
Technically it should already work. I'm not sure why it doesn't work for you.
Is there anything I should look in the database for? I did upgrade from v3, so there might be something left over that’s forcing sessions to expire, but I don’t even know where to start with that. I don’t want to wipe it because I’d lose the last year of history
Just tried uninstalling and reinstalling the manager app again and it did not stay logged in. My iOS shortcut to start my car worked (uses basic auth) but the notification that my car had started did not come through because the app had been logged out.
I might just wipe the database and import just the history and see if that’ll work
After more experimentation, it's looking like the main issue is traccar doesn't add Max-Age to the JSESSIONID cookie, so it defaults to session and the browser/app wipes it whenever it thinks the "session" is over. If traccar added Max-Age to the cookie and periodically reset the cookie with a new Max-Age that would fix it.
Until then, what's working for me is switching to a docker build of nginx with lua support (already using nginx for https reverse proxy) and using that to add Max-Age to the cookie. Set it up last night and I didn't have to login this morning, and remote start notifications are still coming through.
Why does the session change? Are you killing the app?
Just updated from 3.something to 5.3. With the old interface I had the option to stay logged in, and it would stay logged in for a few weeks before asking for my password again. The new interface doesn't have that option on the login screen, and the default session timeout is much shorter, possibly just a few hours. Every time I visit my server's web interface or load the manager app after a few hours, it requires me to insert my password again.
Is there a trick to staying logged in on 5.3 or is that just not supported yet in the new interface?