-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
postgresql-pod.yaml
56 lines (56 loc) · 1.42 KB
/
postgresql-pod.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
apiVersion: v1
kind: Pod
metadata:
name: database
labels:
io.containers.autoupdate: registry
spec:
restartPolicy: OnFailure
containers:
- name: postgresql
image:
docker.io/bitnami/postgresql:15
imagePullPolicy: Always
env:
- name: POSTGRESQL_ENABLE_LDAP
value: yes
- name: POSTGRESQL_LDAP_BASE_DN
value: dc=exploding-hamster,dc=duckdns.org
- name: POSTGRESQL_LDAP_PORT
value: "3389"
- name: POSTGRESQL_LDAP_SEARCH_FILTER
value: (&(uid=$username)(cn=databases))
- name: POSTGRESQL_LDAP_SERVER
value: ldap
- name: POSTGRESQL_PASSWORD
valueFrom:
secretKeyRef:
name: postgresql-secret
key: POSTGRESQL_PASSWORD
resources:
limits:
cpu: 250m
memory: 1024Mi
requests:
cpu: 10m
memory: 128Mi
securityContext:
allowPrivilegeEscalation: false
capabilities:
add:
- CAP_DAC_OVERRIDE
drop:
- ALL
privileged: false
runAsGroup: 1000
runAsNonRoot: true
runAsUser: 0
seccompProfile:
type: RuntimeDefault
volumeMounts:
- name: postgresql-volume
mountPath: /bitnami/postgresql
volumes:
- name: postgresql-volume
persistentVolumeClaim:
claimName: postgresql-pvc