From 9e6af8c0bcdf90a6d876cdf5ad6a580d589e9594 Mon Sep 17 00:00:00 2001 From: "M. Mert Yildiran" Date: Sun, 30 Jul 2023 04:23:53 +0300 Subject: [PATCH] :zap: Enable profiling in the worker when `debug` is enabled --- helm-chart/templates/09-worker-daemon-set.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/helm-chart/templates/09-worker-daemon-set.yaml b/helm-chart/templates/09-worker-daemon-set.yaml index f4f036451..009a9d8a9 100644 --- a/helm-chart/templates/09-worker-daemon-set.yaml +++ b/helm-chart/templates/09-worker-daemon-set.yaml @@ -48,6 +48,15 @@ spec: image: '{{ .Values.tap.docker.registry }}/worker:{{ .Values.tap.docker.tag }}' imagePullPolicy: {{ .Values.tap.docker.imagepullpolicy }} name: kubeshark-worker-daemon-set + {{- if .Values.tap.debug }} + env: + - name: PROFILING_ENABLED + value: "true" + - name: PROFILING_DUMP_PATH + value: "pprof" + - name: PROFILING_INTERVAL_SECONDS + value: "10" + {{- end }} resources: limits: cpu: {{ .Values.tap.resources.worker.limits.cpu }}