Disabled local logins, locked out of site

(Don Glover) #1

Was configuring and testing social logins and had disable local user account. Logged out to test. Now it appears that I can’t log in back in to using the local admin. Is there a way to force it? If not what are my options?

(Jens Maier) #2

You can use the console to fix this.

  1. SSH into your server.
  2. If you’ve followed the official install guide, run cd /var/discourse; ./launcher enter app.
    If you are running a custom Discourse setup (e.g. not based on Docker), do whatever you need to do to get into your Discourse’s production environment.
  3. Run rails c. You’re now in the Rails console; everything from here on is parsed as Ruby commands.
  4. Type:
    SiteSetting.enable_local_logins = true
  5. exit from the container. Local logins should now be reenabled.

Login/Sign up modals empty
(Jeff Atwood) #10

There is also /users/admin-login now for login bypass if you get locked out due to Site Setting mistakes.

(system) #11

(Sam Saffron) #12