From 065cc790fd55644befa9f47f1ae7afb421fc3d13 Mon Sep 17 00:00:00 2001 From: Raffael Schmid Date: Tue, 23 Oct 2012 22:02:01 +0300 Subject: [PATCH] Some more stuff about LDAP --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+), 0 deletions(-) diff --git a/README.md b/README.md index 810d375..205aad8 100644 --- a/README.md +++ b/README.md @@ -280,6 +280,7 @@ GITHUB_ACCESS_SCOPE=repo,public_repo * In `config/config.yml`, set `user_has_username` to `true` * Follow the instructions at https://github.com/cschiewek/devise_ldap_authenticatable to set up the devise_ldap_authenticatable gem. + * Ensure to set ```config.ldap_create_user = true``` in ```config/initializers/devise.rb```, this enables creating the users from LDAP, otherwhise login will not work. * Create a new initializer (e.g. ```config/initializers/devise_ldap.rb```) and add the following code to enable ldap authentication in the User-model: ```ruby Errbit::Config.devise_modules << :ldap_authenticatable @@ -295,6 +296,15 @@ Errbit::Config.devise_modules << :ldap_authenticatable end ``` + * Now login with your user from LDAP, this will create a user in the database + * Open a rails console and set the admin flag for your user: + +```ruby +user = User.first +user.admin = true +user.save! +``` + Upgrading --------- When upgrading Errbit, please run: -- libgit2 0.21.2