mirror of https://github.com/synctv-org/synctv
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.2 KiB
YAML
42 lines
1.2 KiB
YAML
1 month ago
|
{{- if .Values.postgresql.enabled -}}
|
||
|
apiVersion: apps/v1
|
||
|
kind: StatefulSet
|
||
|
metadata:
|
||
|
name: synctv-postgresql
|
||
|
labels:
|
||
|
app: synctv-postgresql
|
||
|
spec:
|
||
|
replicas: {{ .Values.postgresql.replicaCount }}
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app: synctv-postgresql
|
||
|
template:
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: synctv-postgresql
|
||
|
spec:
|
||
|
containers:
|
||
|
- name: postgresql
|
||
|
image: {{ .Values.postgresql.image.repository }}:{{ .Values.postgresql.image.tag }}
|
||
|
imagePullPolicy: {{ .Values.postgresql.image.pullPolicy }}
|
||
|
ports:
|
||
|
- containerPort: {{ .Values.postgresql.service.port }}
|
||
|
env:
|
||
|
- name: POSTGRES_PASSWORD
|
||
|
value: {{ .Values.postgresql.password | quote }}
|
||
|
volumeMounts:
|
||
|
- name: postgresql-storage
|
||
|
mountPath: /var/lib/postgresql/data
|
||
|
volumeClaimTemplates:
|
||
|
- metadata:
|
||
|
name: postgresql-storage
|
||
|
spec:
|
||
|
{{- with .Values.postgresql.storage.storageClass }}
|
||
|
storageClassName: {{ . }}
|
||
|
{{- end }}
|
||
|
accessModes: ["ReadWriteOnce"]
|
||
|
resources:
|
||
|
requests:
|
||
|
storage: {{ .Values.postgresql.storage.size }}
|
||
|
{{- end }}
|