diff --git a/openapi/config-values.yaml b/openapi/config-values.yaml index 68a80d8e..d7b0d37d 100644 --- a/openapi/config-values.yaml +++ b/openapi/config-values.yaml @@ -9,3 +9,13 @@ properties: type: boolean default: false description: Disable sds-node-configurator daemonset + logLevel: + type: string + enum: + - ERROR + - WARN + - INFO + - DEBUG + - TRACE + description: Module log level + default: INFO \ No newline at end of file diff --git a/openapi/doc-ru-config-values.yaml b/openapi/doc-ru-config-values.yaml index 7012bdde..dbd97370 100644 --- a/openapi/doc-ru-config-values.yaml +++ b/openapi/doc-ru-config-values.yaml @@ -2,3 +2,5 @@ type: object properties: disableDs: description: Выключить sds-node-configurator daemonset + logLevel: + description: Уровень логирования для приложений модуля \ No newline at end of file diff --git a/templates/agent/daemonset.yaml b/templates/agent/daemonset.yaml index 37314091..fb02f0b4 100644 --- a/templates/agent/daemonset.yaml +++ b/templates/agent/daemonset.yaml @@ -38,7 +38,17 @@ spec: fieldRef: fieldPath: spec.nodeName - name: LOG_LEVEL - value: "2" # 2-INFO, 3-DEBUG, 4-TRACE +{{- if eq .Values.sdsNodeConfigurator.logLevel "ERROR" }} + value: "0" +{{- else if .Values.sdsNodeConfigurator.logLevel "WARN" }} + value: "1" +{{- else if .Values.sdsNodeConfigurator.logLevel "INFO" }} + value: "2" +{{- else if .Values.sdsNodeConfigurator.logLevel "DEBUG" }} + value: "3" +{{- else if .Values.sdsNodeConfigurator.logLevel "TRACE" }} + value: "4" +{{- end }} volumeMounts: - mountPath: /dev/ name: host-device-dir