diff --git a/deployment/network-operator/charts/nic-configuration-operator-chart/templates/config-daemon.yaml b/deployment/network-operator/charts/nic-configuration-operator-chart/templates/config-daemon.yaml deleted file mode 100644 index 9715cd0fc..000000000 --- a/deployment/network-operator/charts/nic-configuration-operator-chart/templates/config-daemon.yaml +++ /dev/null @@ -1,68 +0,0 @@ -apiVersion: apps/v1 -kind: DaemonSet -metadata: - name: nic-configuration-daemon - namespace: {{ .Release.Namespace }} - labels: - app.kubernetes.io/name: nic-configuration-daemon - app.kubernetes.io/created-by: nic-configuration-operator - app.kubernetes.io/part-of: nic-configuration-operator - {{- include "nic-configuration-operator.labels" . | nindent 4 }} -spec: - selector: - matchLabels: - control-plane: nic-configuration-daemon - {{- include "nic-configuration-operator.selectorLabels" . | nindent 6 }} - template: - metadata: - annotations: - kubectl.kubernetes.io/default-container: nic-configuration-daemon - labels: - control-plane: nic-configuration-daemon - {{- include "nic-configuration-operator.selectorLabels" . | nindent 8 }} - spec: - nodeSelector: {{- toYaml .Values.operator.nodeSelector | nindent 8 }} - serviceAccountName: {{ include "nic-configuration-operator.serviceAccountName" . }} - terminationGracePeriodSeconds: 10 - hostNetwork: true - hostPID: true - priorityClassName: system-node-critical - containers: - - image: "{{ .Values.configDaemon.image.repository }}/{{ .Values.configDaemon.image.name }}:{{ .Values.configDaemon.image.tag | default .Chart.AppVersion }}" - name: nic-configuration-daemon - securityContext: - privileged: true - resources: {{- toYaml .Values.configDaemon.resources | nindent 12 }} - env: - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - - name: NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - {{- if .Values.logLevel}} - - name: LOG_LEVEL - value: {{ .Values.logLevel }} - {{- end}} - volumeMounts: - - name: sys - mountPath: /sys - readOnly: false - - name: proc - mountPath: /proc - readOnly: false - - name: host - mountPath: /host - readOnly: true - volumes: - - name: sys - hostPath: - path: /sys - - name: proc - hostPath: - path: /proc - - name: host - hostPath: - path: / diff --git a/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-config.yaml b/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-config.yaml new file mode 100644 index 000000000..d4103e39b --- /dev/null +++ b/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-config.yaml @@ -0,0 +1,19 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: nic-configuration-operator-config +data: + serviceAccountName: "{{ include "nic-configuration-operator.serviceAccountName" . }}" + configDaemonImage: "{{ .Values.configDaemon.image.repository }}/{{ .Values.configDaemon.image.name }}:{{ .Values.configDaemon.image.tag | default .Chart.AppVersion }}" + {{- if .Values.imagePullSecrets}} + imagePullSecrets: {{ join "," .Values.imagePullSecrets }} + {{- end}} + {{- if .Values.configDaemon.nodeSelector}} + nodeSelector: {{ .Values.configDaemon.nodeSelector | toJson | quote }} + {{- end}} + {{- if .Values.configDaemon.resources}} + resources: {{ .Values.configDaemon.resources | toJson | quote }} + {{- end}} + {{- if .Values.logLevel}} + logLevel: {{ .Values.logLevel }} + {{- end}} \ No newline at end of file diff --git a/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-configmap.yaml b/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-configmap.yaml new file mode 100644 index 000000000..6e4b4c039 --- /dev/null +++ b/deployment/network-operator/charts/nic-configuration-operator-chart/templates/nic-configuration-operator-configmap.yaml @@ -0,0 +1,20 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: nic-configuration-operator-config +data: + serviceAccountName: "{{ include "nic-configuration-operator.serviceAccountName" . }}" + configDaemonImage: "{{ .Values.configDaemon.image.repository }}/{{ .Values.configDaemon.image.name }}:{{ .Values.configDaemon.image.tag | default .Chart.AppVersion }}" + {{- if .Values.imagePullSecrets}} + imagePullSecrets: {{ join "," .Values.imagePullSecrets }} + {{- end}} + {{- if .Values.configDaemon.nodeSelector}} + nodeSelector: {{ .Values.configDaemon.nodeSelector | toJson | quote }} + {{- end}} + {{- if .Values.configDaemon.resources}} + resources: {{ .Values.configDaemon.resources | toJson | quote }} + {{- end}} + {{- if .Values.logLevel}} + logLevel: {{ .Values.logLevel }} + {{- end}} + clusterType: vanilla