Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rails 4 devise: How to log out all users

Im just about to perform an update to my app, I want to log out all users that have remembered session. I mean, once I deploy the update I want to force all the users to log in again.

What is the best way to do it?

like image 484
svelandiag Avatar asked Feb 04 '16 00:02

svelandiag


1 Answers

If you're storing in active_record, just delete all the sessions. rake db:sessions:clear
If cookies, just change your session_token

like image 156
Jefferson Avatar answered Oct 15 '22 04:10

Jefferson