-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathldap-deployment.yaml
60 lines (55 loc) · 1.25 KB
/
ldap-deployment.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
# This name uniquely identifies the Deployment
name: ldap
spec:
strategy:
type: Recreate
template:
metadata:
labels:
# Label is used as selector in the service.
app: ldap
spec:
containers:
- name: ldap
image: osixia/openldap:1.2.4
args: ["--copy-service"]
env:
- name: LDAP_ORGANISATION
value: "RD Test"
- name: LDAP_DOMAIN
value: "rdtest.com"
- name: LDAP_ADMIN_PASSWORD
valueFrom:
secretKeyRef:
name: ldap-password
key: password
ports:
- containerPort: 389
hostPort: 389
volumeMounts:
- mountPath: /container/service/slapd/assets/config/bootstrap/ldif/50-bootstrap.ldif
name: ldif
subPath: 50-bootstrap.ldif
volumes:
- name: ldif
secret:
secretName: bootstrap.ldif
items:
- key: 50-bootstrap.ldif
path: 50-bootstrap.ldif
---
apiVersion: v1
kind: Service
metadata:
name: ldap
spec:
type: LoadBalancer
ports:
- port: 389
targetPort: 389
protocol: TCP
selector:
app: ldap