gitlab配置ldap
请注意文档中的xxx替换为自己实际的
gitlab_rails['ldap_enabled'] = true
gitlab_rails['ldap_servers'] = YAML.load <<-'EOS'
main: # 'main' is the GitLab 'provider ID' of this LDAP server
label: 'LDAP'
host: 'ldap.prod.xxx.com'
port: 389
uid: 'cn'
bind_dn: 'xxxx@kuozhi.com'
password: 'xxxxxx'
encryption: 'plain' # "start_tls" or "simple_tls" or "plain"
timeout: 10
active_directory: true
allow_username_or_email_login: false
block_auto_created_users: false
base: 'OU=xx科技,OU=xxStaff,dc=xx,dc=com'
user_filter: ''
attributes:
email: ['mail']
name: 'Administrator'
first_name: 'givenName'
last_name: 'sn'
EOS