This commit is contained in:
parent
ae1b31a343
commit
82fc4b96c1
|
@ -0,0 +1,39 @@
|
||||||
|
version: '3'
|
||||||
|
|
||||||
|
services:
|
||||||
|
gitlab:
|
||||||
|
image: gitlab/gitlab-ce:12.4.2-ce.0
|
||||||
|
container_name: gitlab-1
|
||||||
|
restart: always
|
||||||
|
hostname: 'gitlab.example.com'
|
||||||
|
environment:
|
||||||
|
GITLAB_OMNIBUS_CONFIG: |
|
||||||
|
external_url 'http://gitlab.example.com'
|
||||||
|
# LDAP配置
|
||||||
|
gitlab_rails['ldap_enabled'] = true
|
||||||
|
gitlab_rails['ldap_servers'] = {
|
||||||
|
'main' => {
|
||||||
|
'label' => 'LDAP',
|
||||||
|
'host' => '192.168.0.121',
|
||||||
|
'port' => 389,
|
||||||
|
'uid' => 'uid',
|
||||||
|
'bind_dn' => 'cn=admin,dc=example,dc=com',
|
||||||
|
'password' => '123456',
|
||||||
|
'encryption' => 'plain',
|
||||||
|
'base' => 'dc=example,dc=com',
|
||||||
|
'active_directory' => false,
|
||||||
|
'allow_username_or_email_login' => true,
|
||||||
|
'lowercase_usernames' => false,
|
||||||
|
'block_auto_created_users' => false,
|
||||||
|
'user_filter' => ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ports:
|
||||||
|
- '80:80'
|
||||||
|
- '443:443'
|
||||||
|
- '22:22'
|
||||||
|
volumes:
|
||||||
|
- './gitlab/config:/etc/gitlab'
|
||||||
|
- './gitlab/logs:/var/log/gitlab'
|
||||||
|
- './gitlab/data:/var/opt/gitlab'
|
||||||
|
shm_size: '256m'
|
Loading…
Reference in New Issue