|
| 1 | +--- |
| 2 | +# Source: opentelemetry-collector/templates/configmap-agent.yaml |
| 3 | +apiVersion: v1 |
| 4 | +kind: ConfigMap |
| 5 | +metadata: |
| 6 | + name: example-opentelemetry-collector-agent |
| 7 | + namespace: default |
| 8 | + labels: |
| 9 | + helm.sh/chart: opentelemetry-collector-0.115.3 |
| 10 | + app.kubernetes.io/name: opentelemetry-collector |
| 11 | + app.kubernetes.io/instance: example |
| 12 | + app.kubernetes.io/version: "0.126.0" |
| 13 | + app.kubernetes.io/managed-by: Helm |
| 14 | + |
| 15 | +data: |
| 16 | + relay: | |
| 17 | + exporters: |
| 18 | + coralogix: |
| 19 | + application_name: otel |
| 20 | + application_name_attributes: |
| 21 | + - k8s.namespace.name |
| 22 | + - service.namespace |
| 23 | + domain: coralogix.com |
| 24 | + logs: |
| 25 | + headers: |
| 26 | + X-Coralogix-Distribution: helm-otel-integration/1.0 |
| 27 | + metrics: |
| 28 | + headers: |
| 29 | + X-Coralogix-Distribution: helm-otel-integration/1.0 |
| 30 | + private_key: ${env:CORALOGIX_PRIVATE_KEY} |
| 31 | + subsystem_name: integration |
| 32 | + subsystem_name_attributes: |
| 33 | + - k8s.deployment.name |
| 34 | + - k8s.statefulset.name |
| 35 | + - k8s.daemonset.name |
| 36 | + - k8s.cronjob.name |
| 37 | + - service.name |
| 38 | + timeout: 30s |
| 39 | + traces: |
| 40 | + headers: |
| 41 | + X-Coralogix-Distribution: helm-otel-integration/1.0 |
| 42 | + debug: {} |
| 43 | + extensions: |
| 44 | + health_check: |
| 45 | + endpoint: ${env:MY_POD_IP}:13133 |
| 46 | + processors: |
| 47 | + batch: {} |
| 48 | + memory_limiter: |
| 49 | + check_interval: 5s |
| 50 | + limit_percentage: 80 |
| 51 | + spike_limit_percentage: 25 |
| 52 | + transform/prometheus: |
| 53 | + error_mode: ignore |
| 54 | + metric_statements: |
| 55 | + - context: metric |
| 56 | + statements: |
| 57 | + - replace_pattern(name, "_total$", "") |
| 58 | + - context: resource |
| 59 | + statements: |
| 60 | + - set(attributes["k8s.pod.ip"], attributes["net.host.name"]) where attributes["service.name"] |
| 61 | + == "opentelemetry-collector" |
| 62 | + - delete_key(attributes, "service_name") where attributes["service.name"] == |
| 63 | + "opentelemetry-collector" |
| 64 | + - context: datapoint |
| 65 | + statements: |
| 66 | + - delete_key(attributes, "service_name") where resource.attributes["service.name"] |
| 67 | + == "opentelemetry-collector" |
| 68 | + - delete_key(attributes, "otel_scope_name") where attributes["service.name"] |
| 69 | + == "opentelemetry-collector" |
| 70 | + receivers: |
| 71 | + otlp: |
| 72 | + protocols: |
| 73 | + grpc: |
| 74 | + endpoint: ${env:MY_POD_IP}:4317 |
| 75 | + http: |
| 76 | + endpoint: ${env:MY_POD_IP}:4318 |
| 77 | + prometheus: |
| 78 | + config: |
| 79 | + scrape_configs: |
| 80 | + - job_name: opentelemetry-collector |
| 81 | + scrape_interval: 30s |
| 82 | + static_configs: |
| 83 | + - targets: |
| 84 | + - ${env:MY_POD_IP}:8888 |
| 85 | + service: |
| 86 | + extensions: |
| 87 | + - health_check |
| 88 | + pipelines: |
| 89 | + logs: |
| 90 | + exporters: |
| 91 | + - debug |
| 92 | + - coralogix |
| 93 | + processors: |
| 94 | + - memory_limiter |
| 95 | + - batch |
| 96 | + receivers: |
| 97 | + - otlp |
| 98 | + metrics: |
| 99 | + exporters: |
| 100 | + - debug |
| 101 | + - coralogix |
| 102 | + processors: |
| 103 | + - memory_limiter |
| 104 | + - transform/prometheus |
| 105 | + - batch |
| 106 | + receivers: |
| 107 | + - otlp |
| 108 | + - prometheus |
| 109 | + traces: |
| 110 | + exporters: |
| 111 | + - debug |
| 112 | + - coralogix |
| 113 | + processors: |
| 114 | + - memory_limiter |
| 115 | + - batch |
| 116 | + receivers: |
| 117 | + - otlp |
| 118 | + telemetry: |
| 119 | + logs: |
| 120 | + encoding: json |
| 121 | + metrics: |
| 122 | + readers: |
| 123 | + - pull: |
| 124 | + exporter: |
| 125 | + prometheus: |
| 126 | + host: ${env:MY_POD_IP} |
| 127 | + port: 8888 |
0 commit comments