Make netchecker log levels configurable (#11334)

* Make netchecker log levels configurable

* use ETCD_LOG_LEVEL
pull/11406/head
Erwan Miran 2024-07-29 08:57:56 +02:00 committed by GitHub
parent 468c5641b2
commit d469503e84
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 11 additions and 3 deletions

View File

@ -94,6 +94,11 @@ netchecker_server_user: 1000
netchecker_agent_group: 1000 netchecker_agent_group: 1000
netchecker_server_group: 1000 netchecker_server_group: 1000
# Log levels
netchecker_agent_log_level: 5
netchecker_server_log_level: 5
netchecker_etcd_log_level: info
# Dashboard # Dashboard
dashboard_replicas: 1 dashboard_replicas: 1

View File

@ -35,7 +35,7 @@ spec:
fieldRef: fieldRef:
fieldPath: spec.nodeName fieldPath: spec.nodeName
args: args:
- "-v=5" - "-v={{ netchecker_agent_log_level }}"
- "-alsologtostderr=true" - "-alsologtostderr=true"
- "-serverendpoint=netchecker-service:8081" - "-serverendpoint=netchecker-service:8081"
- "-reportinterval={{ agent_report_interval }}" - "-reportinterval={{ agent_report_interval }}"

View File

@ -37,7 +37,7 @@ spec:
fieldRef: fieldRef:
fieldPath: spec.nodeName fieldPath: spec.nodeName
args: args:
- "-v=5" - "-v={{ netchecker_agent_log_level }}"
- "-alsologtostderr=true" - "-alsologtostderr=true"
- "-serverendpoint=netchecker-service:8081" - "-serverendpoint=netchecker-service:8081"
- "-reportinterval={{ agent_report_interval }}" - "-reportinterval={{ agent_report_interval }}"

View File

@ -43,7 +43,7 @@ spec:
ports: ports:
- containerPort: 8081 - containerPort: 8081
args: args:
- -v=5 - -v={{ netchecker_server_log_level }}
- -logtostderr - -logtostderr
- -kubeproxyinit=false - -kubeproxyinit=false
- -endpoint=0.0.0.0:8081 - -endpoint=0.0.0.0:8081
@ -51,6 +51,9 @@ spec:
- name: etcd - name: etcd
image: "{{ etcd_image_repo }}:{{ netcheck_etcd_image_tag }}" image: "{{ etcd_image_repo }}:{{ netcheck_etcd_image_tag }}"
imagePullPolicy: {{ k8s_image_pull_policy }} imagePullPolicy: {{ k8s_image_pull_policy }}
env:
- name: ETCD_LOG_LEVEL
value: "{{ netchecker_etcd_log_level }}"
command: command:
- etcd - etcd
- --listen-client-urls=http://127.0.0.1:2379 - --listen-client-urls=http://127.0.0.1:2379