From 0165bccc28aa76336fa2b0af38f1bffb93390247 Mon Sep 17 00:00:00 2001 From: Ning Sun Date: Wed, 18 Dec 2024 11:10:19 +0800 Subject: [PATCH] feat: attempt to enable log collection for datadog agent --- datadog-agent-migration/docker-compose.yml | 1 + datadog-agent-migration/vector.toml | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/datadog-agent-migration/docker-compose.yml b/datadog-agent-migration/docker-compose.yml index d26d858..7033b76 100644 --- a/datadog-agent-migration/docker-compose.yml +++ b/datadog-agent-migration/docker-compose.yml @@ -34,6 +34,7 @@ services: - DD_API_KEY=random_string - DD_DD_URL=http://vector:8000 - DD_HOSTNAME=testagent + - DD_LOGS_ENABLED=true vector: image: docker.io/timberio/vector:0.43.X-alpine diff --git a/datadog-agent-migration/vector.toml b/datadog-agent-migration/vector.toml index d4e83f2..4553bfd 100644 --- a/datadog-agent-migration/vector.toml +++ b/datadog-agent-migration/vector.toml @@ -1,9 +1,10 @@ [sources.datadog] type = "datadog_agent" address = "0.0.0.0:8000" +multiple_outputs = true -[sinks.my_greptimedb] -inputs = ["datadog"] +[sinks.my_greptimedb_metrics] +inputs = ["datadog.metrics"] type = "greptimedb_metrics" endpoint = "greptimedb:4001" dbname = "public" @@ -11,3 +12,10 @@ username = "" password = "" new_naming=true #tls = {} + +[sinks.my_greptimedb_logs] +inputs = ["datadog.logs"] +type = "greptimedb_logs" +table = "demo_logs" +compression = "gzip" +endpoint = "http://greptimedb:4000"