-
Notifications
You must be signed in to change notification settings - Fork 0
/
postgres.yaml
50 lines (50 loc) · 1013 Bytes
/
postgres.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
apiVersion: v1
kind: Service
metadata:
name: postgres
labels:
app: postgres
spec:
selector:
app: postgres
ports:
- name: postgres
protocol: TCP
port: 5432
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
labels:
app: postgres
name: postgres
spec:
replicas: 1
template:
metadata:
labels:
app: postgres
spec:
containers:
- name: postgres
image: ghcr.io/wuvt/postgres:latest
env:
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
name: postgres
key: password
ports:
- containerPort: 5432
volumeMounts:
- name: postgres-data
mountPath: /var/lib/postgresql/data
volumes:
- name: postgres-data
hostPath:
path: /media/local-storage/postgres-data
nodeName: columbia
tolerations:
- key: node-role.kubernetes.io/dbserver
operator: Exists
effect: NoSchedule