@@ -14,13 +14,13 @@ metadata:
1414spec :
1515 type : ClusterIP
1616 ports :
17- - name : tcp-postgresql
17+ - name : postgres
1818 port : 5432
19- targetPort : 5432
19+ protocol : TCP
20+ targetPort : postgres
2021 selector :
21- app : postgresql
22- release : " devtron"
23- role : master
22+ app.kubernetes.io/name : postgres
23+ app.kubernetes.io/instance : devtron
2424---
2525apiVersion : v1
2626kind : Service
@@ -37,12 +37,13 @@ spec:
3737 type : ClusterIP
3838 clusterIP : None
3939 ports :
40- - name : tcp-postgresql
40+ - name : postgres
4141 port : 5432
42- targetPort : 5432
42+ protocol : TCP
43+ targetPort : postgres
4344 selector :
44- app : postgresql
45- release : " devtron"
45+ app.kubernetes.io/name : postgres
46+ app.kubernetes.io/instance : devtron
4647---
4748apiVersion : v1
4849kind : Service
@@ -64,22 +65,21 @@ spec:
6465 port : 9187
6566 targetPort : http-metrics
6667 selector :
67- app : postgresql
68- release : devtron
69- role : master
68+ app.kubernetes.io/name : postgres
69+ app.kubernetes.io/instance : devtron
7070---
7171apiVersion : apps/v1
7272kind : StatefulSet
7373metadata :
7474 name : postgresql-postgresql
75- namespace : devtroncd
7675 labels :
77- app : postgresql
78- release : " devtron"
76+ helm.sh/chart : postgres-0.4.0
77+ app.kubernetes.io/name : postgres
78+ app.kubernetes.io/instance : devtron
79+ app.kubernetes.io/version : " 14.5"
80+ app.kubernetes.io/managed-by : Helm
7981 annotations :
8082 " helm.sh/resource-policy " : keep
81- " meta.helm.sh/release-name " : devtron
82- " meta.helm.sh/release-namespace " : devtroncd
8383spec :
8484 replicas : 1
8585 serviceName : postgresql-postgresql
@@ -88,15 +88,13 @@ spec:
8888 type : RollingUpdate
8989 selector :
9090 matchLabels :
91- app : postgresql
92- release : " devtron"
93- role : master
91+ app.kubernetes.io/name : postgres
92+ app.kubernetes.io/instance : devtron
9493 template :
9594 metadata :
9695 labels :
97- app : postgresql
98- release : " devtron"
99- role : master
96+ app.kubernetes.io/name : postgres
97+ app.kubernetes.io/instance : devtron
10098 spec :
10199 {{- include "common.schedulerConfig" (dict "nodeSelector" $.Values.components.postgres.nodeSelector "tolerations" $.Values.components.postgres.tolerations "imagePullSecrets" $.Values.components.postgres.imagePullSecrets "global" $.Values.global) | indent 6 }}
102100 serviceAccountName : devtron-default-sa
@@ -148,7 +146,7 @@ spec:
148146 {{- toYaml .resources | nindent 12 }}
149147 {{- end }}
150148 ports :
151- - name : tcp-postgresql
149+ - name : postgres
152150 containerPort : 5432
153151 protocol : TCP
154152 env :
@@ -159,11 +157,6 @@ spec:
159157 secretKeyRef :
160158 key : postgresql-password
161159 name : postgresql-postgresql
162- - name : POSTGRES_USER
163- valueFrom :
164- secretKeyRef :
165- name : postgresql-postgresql
166- key : POSTGRES_USER
167160 - name : POSTGRES_HOST_AUTH_METHOD
168161 value : " md5"
169162 - name : POSTGRES_INITDB_ARGS
@@ -219,7 +212,7 @@ spec:
219212 name : configs
220213 - name : metrics
221214 image : {{ include "common.image" (dict "component" $.Values.components.postgres.metrics "global" $.Values.global "extraImage" $.Values.components.postgres.metrics.image ) }}
222- imagePullPolicy : {{ .imagePullPolicy }}
215+ imagePullPolicy : " IfNotPresent "
223216 env :
224217 - name : DATA_SOURCE_URI
225218 value : " 127.0.0.1:5432/orchestrator?sslmode=disable"
@@ -257,6 +250,7 @@ spec:
257250 timeoutSeconds : 5
258251 successThreshold : 1
259252 failureThreshold : 6
253+ volumeMounts :
260254 ports :
261255 - name : http-metrics
262256 containerPort : 9187
@@ -365,4 +359,4 @@ data:
365359 cat /extraconfigs/* >>/configs/postgresql.conf
366360 fi
367361 echo "Initialization done."
368- {{- end }}
362+ {{- end }}
0 commit comments