receivers: otlp: protocols: grpc: endpoint: 0.0.0.0:4317 http: endpoint: 0.0.0.0:4318 filelog: include: - /var/lib/docker/containers/*/*-json.log include_file_path: true operators: - type: json_parser parse_to: attributes on_error: send - type: filter expr: 'attributes["attrs"] == nil' - type: json_parser if: 'attributes["attrs"] != nil' parse_from: attributes["attrs"] parse_to: attributes["docker_attrs"] on_error: send - type: filter expr: | attributes["docker_attrs"] == nil or attributes["docker_attrs"]["tag"] == nil or ( attributes["docker_attrs"]["tag"] != "g2s-aggregator${CONTAINER_SUFFIX}" and attributes["docker_attrs"]["tag"] != "g2s-aggregator-migrations${CONTAINER_SUFFIX}" and attributes["docker_attrs"]["tag"] != "g2s-aggregator-waybill-poller${CONTAINER_SUFFIX}" and attributes["docker_attrs"]["tag"] != "g2s-aggregator-waybill-email-sender${CONTAINER_SUFFIX}" ) on_error: send - type: regex_parser parse_from: attributes["docker_attrs"]["tag"] regex: '^(?Pg2s-aggregator(?:-migrations|-waybill-poller|-waybill-email-sender)?)(?:-stage)?$' on_error: send - type: move from: attributes["service_name"] to: resource["service.name"] on_error: send - type: regex_parser parse_from: attributes["log.file.path"] regex: '^/var/lib/docker/containers/(?P[^/]+)/' on_error: send - type: move from: attributes["container_id"] to: resource["service.instance.id"] on_error: send - type: remove field: attributes["attrs"] on_error: send - type: remove field: attributes["docker_attrs"] on_error: send - type: json_parser parse_from: attributes.log parse_to: attributes on_error: send - type: trace_parser if: | attributes.trace_id != nil and attributes.span_id != nil and attributes.trace_flags != nil trace_id: parse_from: attributes.trace_id span_id: parse_from: attributes.span_id trace_flags: parse_from: attributes.trace_flags on_error: send - type: time_parser parse_from: attributes.timestamp layout: '%Y-%m-%dT%H:%M:%S.%fZ' on_error: send - type: severity_parser parse_from: attributes.level on_error: send - type: move from: attributes.event to: body on_error: send - type: remove field: attributes.log on_error: send docker_stats: endpoint: unix:///var/run/docker.sock collection_interval: 30s container_labels_as_resource_attributes: true api_version: "1.43" processors: resource/env: attributes: - key: deployment.environment value: "${ENV_NAME}" action: upsert - key: service.namespace value: g2s action: upsert resource/version: attributes: - key: service.version value: "${IMAGE_TAG}" action: upsert filter/environment: error_mode: ignore metrics: metric: - '${METRICS_FILTER_EXPRESSION}' exporters: otlp: endpoint: "${SIGNOZ_OTLP_ENDPOINT}" tls: insecure: true service: pipelines: traces: receivers: [otlp] processors: [resource/env, resource/version] exporters: [otlp] logs: receivers: [filelog] processors: [resource/env, resource/version] exporters: [otlp] metrics: receivers: [docker_stats] processors: [filter/environment, resource/env] exporters: [otlp]