Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

why is laravel login me out when using sentry?

I'm new to Laravel and I am working on an application. I am using sentry to handle users and the login system. But even though my session expiration is set very high, I keep being logged out very frequently, at random times. Is that a laravel problem or maybe an incompatibility with Sentry 2? Any ideas?

like image 548
David Ross Avatar asked Jun 17 '14 17:06

David Ross


1 Answers

You didn't mentioned, but I have to ask, do you have more than one laravel application running on the same server? I've noticed that laravel tends to put the cookie session on the root of the server and if you have two Laravel-based applications running on it with the same location / name (by default, it is called laravel_session), they will overwrite each other.

If that is the case, try going into AppName / app / application / config / session.php and either change the path or the cookie component of the driver. I had trouble changing the path of the session, but if you change the name to, let's say, appName_session instead of laravel_Session it should solve your problem.

Hopefully that is what you meant and that it helps. Good luck.

like image 137
Victor Avatar answered Dec 04 '22 03:12

Victor