-
Notifications
You must be signed in to change notification settings - Fork 20
/
Copy path02-otel-collector.yaml
65 lines (62 loc) · 1.88 KB
/
02-otel-collector.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
apiVersion: opentelemetry.io/v1alpha1
kind: OpenTelemetryCollector
metadata:
name: otel
namespace: observability-backend
spec:
image: ghcr.io/open-telemetry/opentelemetry-collector-releases/opentelemetry-collector-contrib:0.74.0
mode: deployment
config: |
receivers:
otlp:
protocols:
grpc:
http:
prometheus:
config:
scrape_configs:
- job_name: 'otel-collector'
scrape_interval: 10s
static_configs:
- targets: [ '0.0.0.0:8888' ]
processors:
batch:
memory_limiter:
check_interval: 1s
limit_percentage: 50
spike_limit_percentage: 30
attributes:
actions:
- key: "http.target"
pattern: ^.*\?player=(?P<player>.*)
action: extract
exporters:
otlp:
endpoint: "http://tempo.observability-backend.svc.cluster.local:55680"
tls:
insecure: true
otlphttp/mimir:
endpoint: "http://mimir.observability-backend.svc.cluster.local:8080/otlp"
loki:
endpoint: "http://loki.observability-backend.svc.cluster.local:3100/loki/api/v1/push"
logging:
service:
# Expose internal telemetry of the collector
# It exposes Prometheus /metrics endpoint, that is scraped by the prometheus receiver
# and the metrics are sent through the pipeline to the metrics backend.
telemetry:
metrics:
address: localhost:8888
pipelines:
traces:
receivers: [otlp]
processors: [memory_limiter, attributes, batch]
exporters: [otlp]
metrics:
receivers: [prometheus, otlp]
processors: [memory_limiter, batch]
exporters: [otlphttp/mimir]
logs:
receivers: [otlp]
processors: [memory_limiter, batch]
exporters: [loki, logging]