Task — engineering-spec@1

"OTel collector scaffold + LGTM compose (validate-config, PII scrub)"

doneTASK-OBS-001
module obs · class product · priority p0 · created 2026-05-15 · shipped null
depends on none · blocks TASK-OBS-002, TASK-OBS-003, TASK-OBS-004, TASK-OBS-005, TASK-OBS-006, TASK-AI-022

TASK-OBS-001: OTel collector scaffold + LGTM compose

Summary

Slice-1 ships the cyberos-obs-collector crate (services/obs-collector/): canonical otel-collector-config.yaml, bearer-token file shape, YAML contract validation in config.rs, token parsing in auth.rs, self-metric name constants in metrics.rs, and the cyberos-obs CLI (validate-config, validate-tokens). deploy/obs/ provides the LGTM backends plus the TASK-OBS-002 obs-proxy in docker-compose.ymlnot a live otelcol-contrib container in compose. Upstream otelcol process supervision, Helm charts, mTLS ingress, and operator rotation/healthcheck shell suites are explicitly deferred.

Problem

The original engineering-spec claimed flat deploy/obs/otel-collector-config.yaml, loki-config.yaml, prometheus-config.yaml, rotate_tokens.sh, healthcheck.sh, and three bash smoke suites that were never built. It used ## §N body grammar (FM-004) and described a five-service compose with a running collector. The as-built surface is the obs-collector validation crate + nested deploy layout (prometheus/, tempo/, grafana/provisioning/) wired to obs-proxy — honest re-spec required before re-entry.

Proposed Solution

Adopt the as-built layout:

Alternatives Considered

Success Metrics

Scope

In scope (as-built):

Out of scope / Non-Goals

Dependencies

depends_on: []. Soft: TASK-OBS-002 obs-proxy already consumes the LGTM backends in deploy/obs/; TASK-AI-022 typed attribute keys (caller-side PII prevention primary over DEC-143 collector scrub).

1. Description (normative)

Acceptance criteria

Verification

cd services && cargo test -p cyberos-obs-collector
cd services && cargo test -p cyberos-obs-collector validate_rejects_missing_pii_scrub
PathCovers
src/config.rs inline testsYAML contract (canonical + missing pii_scrub)
src/auth.rs inline testsBearer-token file parse + reject malformed lines
src/bin/cyberos_obs.rsvalidate-config / validate-tokens CLI surface
config/otel-collector-config.yamlCanonical slice-1 collector pipeline
deploy/obs/docker-compose.ymlLGTM + obs-proxy (no collector container)

AI Authorship Disclosure


batch/9b-obs adopt — TASK-OBS-001 re-spec against as-built obs-collector + deploy/obs LGTM compose.