Skip to content

Commit c7be916

Browse files
author
Mateusz
committed
fixing naming, configuration, mounts for netdata-otel feat
1 parent d17d56f commit c7be916

File tree

5 files changed

+50
-42
lines changed

5 files changed

+50
-42
lines changed

charts/netdata/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ icon: https://netdata.github.io/helmchart/logo.png
1818
appVersion: v2.9.0
1919
dependencies:
2020
- name: opentelemetry-collector
21-
alias: opentelemetryCollector
21+
alias: otel-collector
2222
version: "0.115.0"
2323
repository: "https://open-telemetry.github.io/opentelemetry-helm-charts"
24-
condition: opentelemetryCollector.enabled
24+
condition: otel-collector.enabled

charts/netdata/templates/netdata-otel/deployment.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ spec:
133133
{{- end }}
134134
{{- if .Values.netdataOpentelemetry.persistence.enabled }}
135135
- name: varlib
136-
mountPath: /var/lib/netdata
136+
mountPath: /var/log/netdata/otel
137137
{{- end }}
138138
{{- if .Values.netdataOpentelemetry.extraVolumeMounts -}}
139139
{{ toYaml .Values.netdataOpentelemetry.extraVolumeMounts | nindent 12 }}
@@ -168,7 +168,7 @@ spec:
168168
{{- if .Values.netdataOpentelemetry.persistence.enabled }}
169169
- name: varlib
170170
persistentVolumeClaim:
171-
claimName: {{ template "netdata.name" . }}-otel-varlib
171+
claimName: {{ template "netdata.name" . }}-otel-varlog
172172
{{- end }}
173173
{{- if .Values.netdataOpentelemetry.extraVolumes }}
174174
{{ toYaml .Values.netdataOpentelemetry.extraVolumes | indent 8}}

charts/netdata/templates/netdata-otel/persistentvolumeclaim.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
apiVersion: v1
44
kind: PersistentVolumeClaim
55
metadata:
6-
name: {{ template "netdata.name" . }}-otel-varlib
6+
name: {{ template "netdata.name" . }}-otel-varlog
77
namespace: {{ .Release.Namespace }}
88
labels:
99
app: {{ template "netdata.name" . }}

charts/netdata/templates/netdata-otel/service.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@ spec:
3737
{{- end }}
3838
ports:
3939
- port: {{ .Values.netdataOpentelemetry.service.port }}
40-
targetPort: http
40+
targetPort: {{ .Values.netdataOpentelemetry.service.port }}
4141
protocol: TCP
42-
name: http
42+
name: otel
4343
selector:
4444
app: {{ template "netdata.name" . }}
4545
release: {{ .Release.Name }}

charts/netdata/values.yaml

Lines changed: 43 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,7 @@ restarter:
8989
tag: .auto
9090
pullPolicy: Always
9191
restartPolicy: Never
92-
resources:
93-
{}
92+
resources: {}
9493
# limits:
9594
# cpu: 500m
9695
# memory: 64Mi
@@ -111,8 +110,7 @@ parent:
111110
hostname: "netdata-parent"
112111
enabled: true
113112
port: 19999
114-
resources:
115-
{}
113+
resources: {}
116114
# limits:
117115
# cpu: 4
118116
# memory: 4096Mi
@@ -147,13 +145,11 @@ parent:
147145

148146
priorityClassName: ""
149147

150-
env:
151-
{}
148+
env: {}
152149
## To disable anonymous statistics:
153150
# DO_NOT_TRACK: 1
154151

155-
envFrom:
156-
[]
152+
envFrom: []
157153
## E.g. to read Netdata Cloud claim token from an existing secret "netdata" set this to:
158154
# - secretRef:
159155
# name: netdata
@@ -250,14 +246,12 @@ parent:
250246
child:
251247
enabled: true
252248
port: "{{ .Values.parent.port }}"
253-
updateStrategy:
254-
{}
249+
updateStrategy: {}
255250
# type: RollingUpdate
256251
# rollingUpdate:
257252
# maxUnavailable: 1
258253

259-
resources:
260-
{}
254+
resources: {}
261255
# limits:
262256
# cpu: 4
263257
# memory: 4096Mi
@@ -367,13 +361,11 @@ child:
367361
- name: local
368362
url: http://127.0.0.1:10249/metrics
369363
370-
env:
371-
{}
364+
env: {}
372365
## To disable anonymous statistics:
373366
# DO_NOT_TRACK: 1
374367

375-
envFrom:
376-
[]
368+
envFrom: []
377369
## E.g. to read Netdata Cloud claim token from an existing secret "netdata" set this to:
378370
# - secretRef:
379371
# name: netdata
@@ -386,16 +378,14 @@ child:
386378
rooms: ""
387379
url: "https://api.netdata.cloud"
388380

389-
extraVolumeMounts:
390-
[]
381+
extraVolumeMounts: []
391382
## Additional volume mounts for netdata child
392383
## E.g to mount all disks under / to be monitored via the diskspace plugin
393384
# - name: hostroot
394385
# mountPath: /host/root
395386
# readOnly: true
396387
# mountPropagation: HostToContainer
397-
extraVolumes:
398-
[]
388+
extraVolumes: []
399389
## Additional volumes for netdata child
400390
## E.g to mount all disks under / to be monitored via the diskspace plugin
401391
# - name: hostroot
@@ -407,8 +397,7 @@ k8sState:
407397
enabled: true
408398
port: "{{ .Values.parent.port }}"
409399

410-
resources:
411-
{}
400+
resources: {}
412401
# limits:
413402
# cpu: 4
414403
# memory: 4096Mi
@@ -518,13 +507,11 @@ k8sState:
518507
- name: k8s_state
519508
update_every: 1
520509
521-
env:
522-
{}
510+
env: {}
523511
## To disable anonymous statistics:
524512
# DO_NOT_TRACK: 1
525513

526-
envFrom:
527-
[]
514+
envFrom: []
528515
## E.g. to read Netdata Cloud claim token from an existing secret "netdata" set this to:
529516
# - secretRef:
530517
# name: netdata
@@ -560,8 +547,7 @@ netdataOpentelemetry:
560547
## Only to be used with type ClusterIP
561548
# clusterIP: 10.1.2.3
562549

563-
resources:
564-
{}
550+
resources: {}
565551
# limits:
566552
# cpu: 4
567553
# memory: 4096Mi
@@ -605,7 +591,7 @@ netdataOpentelemetry:
605591
enabled: true
606592
## Set '-' as the storageclass to get a volume from the default storage class.
607593
storageclass: "-"
608-
volumesize: 5Gi
594+
volumesize: 10Gi
609595

610596
configs:
611597
netdata:
@@ -631,6 +617,8 @@ netdataOpentelemetry:
631617
proc = no
632618
cgroups = no
633619
enable running new plugins = no
620+
otel = yes
621+
journal-viewer = yes
634622
slabinfo = no
635623
perf = no
636624
go.d = yes
@@ -652,14 +640,34 @@ netdataOpentelemetry:
652640
buffer size bytes = 1048576
653641
reconnect delay seconds = 5
654642
initial clock resync iterations = 60
655-
656-
env:
657-
{}
643+
otel:
644+
enabled: true
645+
path: /etc/netdata/otel.yaml
646+
data: |
647+
endpoint:
648+
path: "0.0.0.0:4317"
649+
tls_cert_path: null
650+
tls_key_path: null
651+
tls_ca_cert_path: null
652+
metrics:
653+
print_flattened: false
654+
buffer_samples: 10
655+
throttle_charts: 100
656+
chart_configs_dir: otel.d/v1/metrics
657+
logs:
658+
journal_dir: otel/v1
659+
size_of_journal_file: "100MB"
660+
number_of_journal_files: 10
661+
size_of_journal_files: "1GB"
662+
duration_of_journal_files: "7 days"
663+
duration_of_journal_file: "2 hours"
664+
store_otlp_json: false
665+
666+
env: {}
658667
## To disable anonymous statistics:
659668
# DO_NOT_TRACK: 1
660669

661-
envFrom:
662-
[]
670+
envFrom: []
663671
## E.g. to read Netdata Cloud claim token from an existing secret "netdata" set this to:
664672
# - secretRef:
665673
# name: netdata
@@ -680,7 +688,7 @@ netdataOpentelemetry:
680688
# This is an optional component that allows to gather logs from k8s cluster.
681689
# If you already have an exporter of any kind, just point it to the netdata-otel service
682690
# Documentation: https://opentelemetry.io/docs/platforms/kubernetes/helm/collector/
683-
opentelemetryCollector:
691+
otel-collector:
684692
# Set to true to enable the OpenTelemetry Collector
685693
enabled: false
686694

0 commit comments

Comments
 (0)