diff --git a/chart/templates/otel-collector/configmap.yaml b/chart/templates/otel-collector/configmap.yaml index 81cb32bb..c0eb32a2 100644 --- a/chart/templates/otel-collector/configmap.yaml +++ b/chart/templates/otel-collector/configmap.yaml @@ -23,7 +23,7 @@ data: service: pipelines: - logs: + traces: receivers: [otlp] processors: [memory_limiter] - exporters: [exporters] + exporters: [debug] diff --git a/chart/templates/otel-collector/deployment.yaml b/chart/templates/otel-collector/deployment.yaml index c076839d..a141bed9 100644 --- a/chart/templates/otel-collector/deployment.yaml +++ b/chart/templates/otel-collector/deployment.yaml @@ -10,14 +10,15 @@ metadata: {{- end }} spec: selector: - matchLabels: - app: opentelemetry - component: otel-collector + matchLabels: matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: otel-collector template: metadata: - labels: - app: opentelemetry - component: otel-collector + annotations: + checksum/config: {{ include (print $.Template.BasePath "/otel-collector/configmap.yaml") . | sha256sum }} + cluster-autoscaler.kubernetes.io/safe-to-evict: "true" + labels: {{- include "common.labels.standard" . | nindent 8 }} + app.kubernetes.io/component: otel-collector spec: securityContext: fsGroup: 101 @@ -25,6 +26,10 @@ spec: - 2345 containers: - name: otel-collector + ports: + - containerPort: 4318 + name: metrics + protocol: TCP image: otel/opentelemetry-collector-contrib:0.115.1 resources: limits: diff --git a/chart/templates/otel-collector/service.yaml b/chart/templates/otel-collector/service.yaml index cf41bb06..3742008f 100644 --- a/chart/templates/otel-collector/service.yaml +++ b/chart/templates/otel-collector/service.yaml @@ -10,8 +10,10 @@ metadata: {{- end }} spec: ports: - - name: metrics # Default endpoint for querying metrics. + - name: metrics port: 4318 + protocol: TCP + targetPort: metrics selector: {{- include "common.labels.matchLabels" . | nindent 4 }} app.kubernetes.io/component: otel-collector