LDAP Authentication With Gitlab Server
LDAP Authentication with GitLab, When you’re worried about the security on the git-lab server. It’s a good idea to authenticate the users using the LDAP server. So, Nobody can log in to your git-lab server until their account exists on the AD server. We can configure the GitLab server with active directory or LDAP on Linux.
Check Out: Install Gitlab
Note: You must have LDAP Server configured and both servers should be communicated to each other.
Gitlab Provides you to Authenticate users with AD Server. Once you did it. You won’t see admin user because by default everyone will be Admin privileges before integrating this with AD. So You will have to make any user to admin by command line.
Check Gitlab Server Status
Create an Organisational Unit in AD server For Gitlab Server
Under OU IT, I have created a user “git” & “panki” and created a password for both the users.
Check Out: How To Disable Signup On Gitlab
Go the vim /etc/gitlab/gitlab.rb file and look for LDAP
You must have OU, CN, DC, User & password Values to accomplish this work.
As you can see I have these all defined in the below images.
Once you are done with these settings then do not forget to run the below command otherwise changes will not be done.
Check Out: Redirection HTTP To HTTPS
After these configured, You can check your settings are correct with LDAP
You will see the output like this it means your GitLab server is communicating with LDAP Server.
If you do not see any user here it means you need to check your settings again.
Check Out: Check Logs In Git
Go to your Gitlab Server and try to login with an AD user.
Now see I’m able to login with “Panki” User in GitLab server
YouTube Link: LDAP authentication GITLAB
You’re done gitlab with active directory configure ldap