From cdb56c92812922b857ce5be34428dab6c5b2af0e Mon Sep 17 00:00:00 2001 From: Rakshit Menpara <205111+deltasquare4@users.noreply.github.com> Date: Sat, 1 Apr 2023 11:59:07 +0530 Subject: [PATCH] Fix freeipa chart? --- charts/freeipa/templates/service.yaml | 54 +++++++++---------- charts/freeipa/templates/statefulset.yaml | 4 ++ .../templates/tests/test-connection.yaml | 15 ------ charts/freeipa/values.yaml | 2 + 4 files changed, 33 insertions(+), 42 deletions(-) delete mode 100644 charts/freeipa/templates/tests/test-connection.yaml diff --git a/charts/freeipa/templates/service.yaml b/charts/freeipa/templates/service.yaml index d72380d..673df9b 100644 --- a/charts/freeipa/templates/service.yaml +++ b/charts/freeipa/templates/service.yaml @@ -37,31 +37,31 @@ spec: loadBalancerIP: {{ .Values.service.loadBalancerIP }} {{- end }} ports: - - name: ldaps - port: 636 - protocol: TCP - targetPort: 636 - - name: http - port: {{ .Values.service.port }} - targetPort: 80 - - name: https - port: 443 - targetPort: 443 - {{- if .Values.args.setupdns }} - - name: dns-udp - port: 53 - protocol: UDP - targetPort: 53 - {{- end}} - - name: kerberos-tcp - port: 88 - protocol: TCP - targetPort: 88 - - name: kerberos-udp - port: 88 - protocol: UDP - targetPort: 88 - {{- if .Values.service.extraPorts }} - {{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} - {{- end }} + - name: ldaps + port: 636 + protocol: TCP + targetPort: 636 + - name: http + port: {{ .Values.service.port }} + targetPort: 80 + - name: https + port: 443 + targetPort: 443 + {{- if .Values.args.setupdns }} + - name: dns-udp + port: 53 + protocol: UDP + targetPort: 53 + {{- end}} + - name: kerberos-tcp + port: 88 + protocol: TCP + targetPort: 88 + - name: kerberos-udp + port: 88 + protocol: UDP + targetPort: 88 + {{- if .Values.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} + {{- end }} selector: {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/freeipa/templates/statefulset.yaml b/charts/freeipa/templates/statefulset.yaml index 0aa9184..09efb5d 100644 --- a/charts/freeipa/templates/statefulset.yaml +++ b/charts/freeipa/templates/statefulset.yaml @@ -52,6 +52,9 @@ spec: {{- else if .Values.command }} command: {{- include "common.tplvalues.render" (dict "value" .Values.command "context" $) | nindent 12 }} {{- end }} + {{- if .Values.diagnosticMode.enabled }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else }} args: - -U - --realm={{ default "localhost.com" .Values.args.realm }} @@ -77,6 +80,7 @@ spec: {{- if .Values.args.sshtrustdns }} - --ssh-trust-dns {{- end }} + {{- end }} ports: {{- if .Values.args.setupdns }} - containerPort: 53 diff --git a/charts/freeipa/templates/tests/test-connection.yaml b/charts/freeipa/templates/tests/test-connection.yaml deleted file mode 100644 index b3bc1b8..0000000 --- a/charts/freeipa/templates/tests/test-connection.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "freeipa.fullname" . }}-test-connection" - labels: - {{- include "freeipa.labels" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: ['{{ include "freeipa.fullname" . }}:{{ .Values.service.port }}'] - restartPolicy: Never diff --git a/charts/freeipa/values.yaml b/charts/freeipa/values.yaml index fa57e6b..b02c9db 100644 --- a/charts/freeipa/values.yaml +++ b/charts/freeipa/values.yaml @@ -39,6 +39,8 @@ image: # machineconfig: # ignition_version: 3.1.0 +command: {} + args: realm: EXAMPLE.ORG domain: example.org