7
7
8
8
[ hub ] : https://hub.docker.com/r/osixia/openldap/
9
9
10
- Latest release: 1.1.1 - OpenLDAP 2.4.40 - [ Changelog] ( CHANGELOG.md ) | [ Docker Hub] ( https://hub.docker.com/r/osixia/openldap/ )
10
+ Latest release: 1.1.2 - OpenLDAP 2.4.40 - [ Changelog] ( CHANGELOG.md ) | [ Docker Hub] ( https://hub.docker.com/r/osixia/openldap/ )
11
11
12
12
A docker image to run OpenLDAP.
13
13
@@ -37,7 +37,7 @@ A docker image to run OpenLDAP.
37
37
- [Link environment file](#link-environment-file)
38
38
- [Make your own image or extend this image](#make-your-own-image-or-extend-this-image)
39
39
- [ Advanced User Guide] ( #advanced-user-guide )
40
- - [Extend osixia/openldap:1.1.1 image](#extend-osixiaopenldap111 -image)
40
+ - [Extend osixia/openldap:1.1.2 image](#extend-osixiaopenldap112 -image)
41
41
- [Make your own openldap image](#make-your-own-openldap-image)
42
42
- [Tests](#tests)
43
43
- [Kubernetes](#kubernetes)
@@ -55,7 +55,7 @@ If you find this image useful here's how you can help:
55
55
## Quick Start
56
56
Run OpenLDAP docker image:
57
57
58
- docker run --name my-openldap-container --detach osixia/openldap:1.1.1
58
+ docker run --name my-openldap-container --detach osixia/openldap:1.1.2
59
59
60
60
This start a new container with OpenLDAP running inside. Let's make the first search in our LDAP container:
61
61
@@ -91,7 +91,7 @@ It will create an empty ldap for the company **Example Inc.** and the domain **e
91
91
By default the admin has the password ** admin** . All those default settings can be changed at the docker command line, for example:
92
92
93
93
docker run --env LDAP_ORGANISATION="My Company" --env LDAP_DOMAIN="my-company.com" \
94
- --env LDAP_ADMIN_PASSWORD="JonSn0w" --detach osixia/openldap:1.1.1
94
+ --env LDAP_ADMIN_PASSWORD="JonSn0w" --detach osixia/openldap:1.1.2
95
95
96
96
#### Data persistence
97
97
@@ -115,7 +115,7 @@ simply mount this directories as a volume to `/var/lib/ldap` and `/etc/ldap/slap
115
115
116
116
docker run --volume /data/slapd/database:/var/lib/ldap \
117
117
--volume /data/slapd/config:/etc/ldap/slapd.d
118
- --detach osixia/openldap:1.1.1
118
+ --detach osixia/openldap:1.1.2
119
119
120
120
You can also use data volume containers. Please refer to:
121
121
> [ https://docs.docker.com/userguide/dockervolumes/ ] ( https://docs.docker.com/userguide/dockervolumes/ )
@@ -133,7 +133,7 @@ If you are looking for a simple solution to administrate your ldap server you ca
133
133
#### Use auto-generated certificate
134
134
By default TLS is enable, a certificate is created with the container hostname (it can be set by docker run --hostname option eg: ldap.example.org).
135
135
136
- docker run --hostname ldap.my-company.com --detach osixia/openldap:1.1.1
136
+ docker run --hostname ldap.my-company.com --detach osixia/openldap:1.1.2
137
137
138
138
#### Use your own certificate
139
139
@@ -143,24 +143,24 @@ You can set your custom certificate at run time, by mounting a directory contain
143
143
--env LDAP_TLS_CRT_FILENAME=my-ldap.crt \
144
144
--env LDAP_TLS_KEY_FILENAME=my-ldap.key \
145
145
--env LDAP_TLS_CA_CRT_FILENAME=the-ca.crt \
146
- --detach osixia/openldap:1.1.1
146
+ --detach osixia/openldap:1.1.2
147
147
148
148
Other solutions are available please refer to the [ Advanced User Guide] ( #advanced-user-guide )
149
149
150
150
#### Disable TLS
151
151
Add --env LDAP_TLS=false to the run command:
152
152
153
- docker run --env LDAP_TLS=false --detach osixia/openldap:1.1.1
153
+ docker run --env LDAP_TLS=false --detach osixia/openldap:1.1.2
154
154
155
155
### Multi master replication
156
156
Quick example, with the default config.
157
157
158
158
#Create the first ldap server, save the container id in LDAP_CID and get its IP:
159
- LDAP_CID=$(docker run --hostname ldap.example.org --env LDAP_REPLICATION=true --detach osixia/openldap:1.1.1 )
159
+ LDAP_CID=$(docker run --hostname ldap.example.org --env LDAP_REPLICATION=true --detach osixia/openldap:1.1.2 )
160
160
LDAP_IP=$(docker inspect -f "{{ .NetworkSettings.IPAddress }}" $LDAP_CID)
161
161
162
162
#Create the second ldap server, save the container id in LDAP2_CID and get its IP:
163
- LDAP2_CID=$(docker run --hostname ldap2.example.org --env LDAP_REPLICATION=true --detach osixia/openldap:1.1.1 )
163
+ LDAP2_CID=$(docker run --hostname ldap2.example.org --env LDAP_REPLICATION=true --detach osixia/openldap:1.1.2 )
164
164
LDAP2_IP=$(docker inspect -f "{{ .NetworkSettings.IPAddress }}" $LDAP2_CID)
165
165
166
166
#Add the pair "ip hostname" to /etc/hosts on each containers,
@@ -196,7 +196,7 @@ You may have some problems with mounted files on some systems. The startup scrip
196
196
197
197
To fix that run the container with ` --copy-service ` argument :
198
198
199
- docker run [your options] osixia/openldap:1.1.1 --copy-service
199
+ docker run [your options] osixia/openldap:1.1.2 --copy-service
200
200
201
201
### Debug
202
202
@@ -205,11 +205,11 @@ Available levels are: `none`, `error`, `warning`, `info`, `debug` and `trace`.
205
205
206
206
Example command to run the container in ` debug ` mode:
207
207
208
- docker run --detach osixia/openldap:1.1.1 --loglevel debug
208
+ docker run --detach osixia/openldap:1.1.2 --loglevel debug
209
209
210
210
See all command line options:
211
211
212
- docker run osixia/openldap:1.1.1 --help
212
+ docker run osixia/openldap:1.1.2 --help
213
213
214
214
215
215
## Environment Variables
@@ -233,6 +233,7 @@ This helps to keep your container configuration secret. If you don't care all en
233
233
Required and used for new ldap server only:
234
234
- ** LDAP_ORGANISATION** : Organisation name. Defaults to ` Example Inc. `
235
235
- ** LDAP_DOMAIN** : Ldap domain. Defaults to ` example.org `
236
+ - ** LDAP_BASE_DN** : Ldap base DN. If empty automatically set from LDAP_DOMAIN value. Defaults to ` (empty) `
236
237
- ** LDAP_ADMIN_PASSWORD** Ldap Admin password. Defaults to ` admin `
237
238
- ** LDAP_CONFIG_PASSWORD** Ldap Config password. Defaults to ` config `
238
239
@@ -267,7 +268,7 @@ Replication options:
267
268
268
269
If you want to set this variable at docker run command add the tag `#PYTHON2BASH:` and convert the yaml in python:
269
270
270
- docker run --env LDAP_REPLICATION_HOSTS="#PYTHON2BASH:['ldap://ldap.example.org','ldap://ldap2.example.org']" --detach osixia/openldap:1.1.1
271
+ docker run --env LDAP_REPLICATION_HOSTS="#PYTHON2BASH:['ldap://ldap.example.org','ldap://ldap2.example.org']" --detach osixia/openldap:1.1.2
271
272
272
273
To convert yaml to python online: http://yaml-online-parser.appspot.com/
273
274
@@ -282,7 +283,7 @@ Other environment variables:
282
283
Environment variables can be set by adding the --env argument in the command line, for example:
283
284
284
285
docker run --env LDAP_ORGANISATION="My company" --env LDAP_DOMAIN="my-company.com" \
285
- --env LDAP_ADMIN_PASSWORD="JonSn0w" --detach osixia/openldap:1.1.1
286
+ --env LDAP_ADMIN_PASSWORD="JonSn0w" --detach osixia/openldap:1.1.2
286
287
287
288
Be aware that environment variable added in command line will be available at any time
288
289
in the container. In this example if someone manage to open a terminal in this container
@@ -293,28 +294,28 @@ he will be able to read the admin password in clear text from environment variab
293
294
For example if your environment files ** my-env.yaml** and ** my-env.yaml.startup** are in /data/ldap/environment
294
295
295
296
docker run --volume /data/ldap/environment:/container/environment/01-custom \
296
- --detach osixia/openldap:1.1.1
297
+ --detach osixia/openldap:1.1.2
297
298
298
299
Take care to link your environment files folder to ` /container/environment/XX-somedir ` (with XX < 99 so they will be processed before default environment files) and not directly to ` /container/environment ` because this directory contains predefined baseimage environment files to fix container environment (INITRD, LANG, LANGUAGE and LC_CTYPE).
299
300
300
301
Note: the container will try to delete the ** \* .yaml.startup** file after the end of startup files so the file will also be deleted on the docker host. To prevent that : use --volume /data/ldap/environment:/container/environment/01-custom** : ro ** or set all variables in ** \* .yaml** file and don't use ** \* .yaml.startup** :
301
302
302
303
docker run --volume /data/ldap/environment/my-env.yaml:/container/environment/01-custom/env.yaml \
303
- --detach osixia/openldap:1.1.1
304
+ --detach osixia/openldap:1.1.2
304
305
305
306
#### Make your own image or extend this image
306
307
307
308
This is the best solution if you have a private registry. Please refer to the [ Advanced User Guide] ( #advanced-user-guide ) just below.
308
309
309
310
## Advanced User Guide
310
311
311
- ### Extend osixia/openldap:1.1.1 image
312
+ ### Extend osixia/openldap:1.1.2 image
312
313
313
314
If you need to add your custom TLS certificate, bootstrap config or environment files the easiest way is to extends this image.
314
315
315
316
Dockerfile example:
316
317
317
- FROM osixia/openldap:1.1.1
318
+ FROM osixia/openldap:1.1.2
318
319
MAINTAINER Your Name <[email protected] >
319
320
320
321
ADD bootstrap /container/service/slapd/assets/config/bootstrap
@@ -333,7 +334,7 @@ Clone this project:
333
334
Adapt Makefile, set your image NAME and VERSION, for example:
334
335
335
336
NAME = osixia/openldap
336
- VERSION = 1.1.1
337
+ VERSION = 1.1.2
337
338
338
339
become:
339
340
NAME = cool-guy/openldap
0 commit comments