Skip to content

Commit 7edfa23

Browse files
committed
Replace base otel collector with grafana alloy
1 parent 9115447 commit 7edfa23

File tree

3 files changed

+39
-33
lines changed

3 files changed

+39
-33
lines changed

config.alloy

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
otelcol.exporter.otlp "jaeger" {
2+
client {
3+
endpoint = "jaeger:4317"
4+
5+
tls {
6+
insecure = true
7+
}
8+
}
9+
}
10+
11+
otelcol.exporter.debug "console" {
12+
verbosity = "Detailed"
13+
}
14+
15+
otelcol.processor.batch "default" {
16+
output {
17+
traces = [otelcol.exporter.otlp.jaeger.input]
18+
}
19+
}
20+
21+
otelcol.receiver.otlp "default" {
22+
grpc { }
23+
24+
output {
25+
metrics = [otelcol.exporter.debug.console.input]
26+
logs = [otelcol.exporter.debug.console.input]
27+
traces = [otelcol.processor.batch.default.input]
28+
}
29+
}

docker-compose.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,19 @@ services:
5959
- "14268:14268" # HTTP port for spans
6060

6161
otel-collector:
62-
image: otel/opentelemetry-collector-contrib
62+
image: grafana/alloy:latest
6363
depends_on:
6464
- jaeger
65+
ports:
66+
- "12345:12345"
6567
volumes:
66-
- ./otel-collector-config.yaml:/etc/otelcol-contrib/config.yaml
68+
- ./config.alloy:/etc/alloy/config.alloy
69+
command:
70+
- run
71+
- --server.http.listen-addr=0.0.0.0:12345
72+
- --stability.level=experimental
73+
# - --stability.level=public-preview
74+
- /etc/alloy/config.alloy
6775

6876
redis:
6977
image: redis

otel-collector-config.yaml

Lines changed: 0 additions & 31 deletions
This file was deleted.

0 commit comments

Comments
 (0)