diff --git a/helm/kubernetes-operator/templates/deployment.yaml b/helm/kubernetes-operator/templates/deployment.yaml index 117b3eb..6934396 100644 --- a/helm/kubernetes-operator/templates/deployment.yaml +++ b/helm/kubernetes-operator/templates/deployment.yaml @@ -87,8 +87,9 @@ spec: periodSeconds: {{ .Values.operator.livenessProbe.periodSeconds }} successThreshold: {{ .Values.operator.livenessProbe.successThreshold }} timeoutSeconds: {{ .Values.operator.livenessProbe.timeoutSeconds }} - {{- if or .Values.netbirdAPI.key .Values.netbirdAPI.keyFromSecret }} + {{- if or .Values.netbirdAPI.key .Values.netbirdAPI.keyFromSecret .Values.operator.logLevel }} env: + {{- if or .Values.netbirdAPI.key .Values.netbirdAPI.keyFromSecret }} - name: NB_API_KEY valueFrom: secretKeyRef: @@ -99,6 +100,11 @@ spec: name: {{ include "kubernetes-operator.fullname" . }} key: NB_API_KEY {{- end }} + {{- end }} + {{- if .Values.operator.logLevel }} + - name: NB_LOG_LEVEL + value: {{ .Values.operator.logLevel | quote }} + {{- end }} {{- end }} readinessProbe: failureThreshold: 3 diff --git a/helm/kubernetes-operator/values.yaml b/helm/kubernetes-operator/values.yaml index b02113a..7a203c9 100644 --- a/helm/kubernetes-operator/values.yaml +++ b/helm/kubernetes-operator/values.yaml @@ -90,7 +90,6 @@ operator: seccompProfile: type: RuntimeDefault - # This is for setting up a service more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/ service: # This sets the service type more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types @@ -121,6 +120,9 @@ operator: successThreshold: 1 timeoutSeconds: 1 + # Log level for NetBird operator (e.g., debug, info, warn, error) + logLevel: "" + # Additional volumes on the output Deployment definition. volumes: []