update
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
{{/*
|
||||
Headless service: stable per-pod DNS for the StatefulSet
|
||||
(<fullname>-db-0.<fullname>-db-headless). Required by the StatefulSet spec.
|
||||
*/}}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "it-cost-dashboard.fullname" . }}-db-headless
|
||||
labels:
|
||||
{{- include "it-cost-dashboard.componentLabels" (dict "ctx" . "component" "db") | nindent 4 }}
|
||||
spec:
|
||||
clusterIP: None
|
||||
ports:
|
||||
- name: mysql
|
||||
port: {{ .Values.db.port }}
|
||||
targetPort: mysql
|
||||
protocol: TCP
|
||||
selector:
|
||||
{{- include "it-cost-dashboard.componentSelectorLabels" (dict "ctx" . "component" "db") | nindent 4 }}
|
||||
---
|
||||
{{/*
|
||||
Normal ClusterIP service. This is what DATABASE_URL and the wait-for-db
|
||||
initContainer target — simpler than per-pod DNS and sufficient for a
|
||||
single-primary MySQL.
|
||||
*/}}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "it-cost-dashboard.dbServiceName" . }}
|
||||
labels:
|
||||
{{- include "it-cost-dashboard.componentLabels" (dict "ctx" . "component" "db") | nindent 4 }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- name: mysql
|
||||
port: {{ .Values.db.port }}
|
||||
targetPort: mysql
|
||||
protocol: TCP
|
||||
selector:
|
||||
{{- include "it-cost-dashboard.componentSelectorLabels" (dict "ctx" . "component" "db") | nindent 4 }}
|
||||
Reference in New Issue
Block a user