Skip to content
All flows
traces
metrics
logs

K8s Production Gateway

Cluster-level gateway that receives OTLP from apps and node agents, tails pod logs, stamps deployment.environment, deletes a PII attribute, and ships everything to your OTLP/HTTP backend with a debug tap on logs.

The cluster's central collector: applications and node agents send OTLP here, and the gateway also tails pod logs directly for anything that only writes to stdout. Every record gets `deployment.environment: production` stamped on the resource, and the attributes processor deletes `user.ssn` before anything leaves the cluster — extend that list with whatever your compliance reviews turn up. Export goes to your OTLP/HTTP backend via `OTLP_GATEWAY_ENDPOINT` (a Grafana Cloud OTLP gateway URL works verbatim). The debug exporter on the logs pipeline prints basic output for on-cluster troubleshooting; drop it from the pipeline once the setup is proven.

Before you use this

Sends data to

debug
otlphttp

You'll need to set these before it runs

OTLP_GATEWAY_ENDPOINT

The configuration

collector v0.147.0
# OpenTelemetry Collector Configuration
# Generated by Telflo

receivers:
  otlp:
    protocols:
      grpc:
        endpoint: '0.0.0.0:4317'
      http:
        endpoint: '0.0.0.0:4318'
  filelog:
    include:
      - '/var/log/pods/*/*/*.log'
    start_at: 'end'
processors:
  memory_limiter:
    check_interval: '1s'
    limit_percentage: 80
    spike_limit_percentage: 25
  resource:
    attributes:
      - key: 'deployment.environment'
        value: 'production'
        action: 'upsert'
  batch:
    timeout: '10s'
    send_batch_size: 1024
  attributes:
    actions:
      - key: 'user.ssn'
        action: 'delete'
exporters:
  otlphttp:
    endpoint: '${env:OTLP_GATEWAY_ENDPOINT}' # e.g. https://otlp-gateway-<stack>.grafana.net/otlp
  debug:
    verbosity: 'basic'
extensions:
  health_check:
    endpoint: '0.0.0.0:13133'
service:
  extensions: [health_check]
  pipelines:
    traces:
      receivers: [otlp]
      processors: [memory_limiter, resource, batch]
      exporters: [otlphttp]
    metrics:
      receivers: [otlp]
      processors: [memory_limiter, resource, batch]
      exporters: [otlphttp]
    logs:
      receivers: [otlp, filelog]
      processors: [memory_limiter, resource, attributes, batch]
      exporters: [otlphttp, debug]

Validated against otelcol-contrib v0.147.0. Fill in the ${env:…} placeholders before running it.

kubernetes
gateway
production