feat(collectionagent): add ecs ec2 collection agent - #192
Open
Nageshbansal wants to merge 2 commits into
Open
Conversation
Nageshbansal
force-pushed
the
feat/runner
branch
2 times, most recently
from
September 3, 2026 15:57
9e86648 to
52024fb
Compare
On a DAEMON the ecs and docker detectors answer for the collector's own task, so every container's logs carried the agent's identity. The agent detects env and ec2 only, and lifts the four ECS labels that docker's json-file driver copies into each line onto the log's resource, carving container.id out of the file path. A task definition without the labels option still produces records, carrying container.id alone. Adds filelog/host over the instance's own logs, which the /hostfs mount the task already carries reaches. Both containers log to the none driver. ECS otherwise falls back to json-file and the agent tails itself through the docker-containers mount. Renames the cloud resources onto the <scope>-<type>[-<qualifier>] grammar: the IAM roles gain their type, and the AppConfig application and its deployment strategy stop sharing a name with the workload. The example README gains the labels requirement, the patch that swaps the agent's own log driver for awslogs, and the name-length caveat.
Nageshbansal
force-pushed
the
feat/ca/ecsec2
branch
from
September 4, 2026 10:04
c528616 to
7ef79d0
Compare
Nageshbansal
marked this pull request as ready for review
September 4, 2026 10:07
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Features
ecs/ec2/terraformCollectionAgent casting: a DAEMON service running one stock contrib collector per container instance on host networking, with OTLP,hostmetrics,docker_statsandfilelog.container.idout of the file path. A task definition without thelabelsoption still produces records, carryingcontainer.idalone.envandec2only. On a DAEMON theecsanddockerdetectors answer for the collector's own task and would stamp every container's telemetry with the agent's identity./var/log/messages,/var/log/secure,/var/log/ecs/*.log) asservice.name=ecs-host.nonelog driver, so the collector does not tail itself through the docker-containers mount.foundry.signoz.io/ecs-region,ecs-cluster-arn,ecs-task-role-arn,ecs-task-execution-role-arn.labelsblock every task definition needs for its logs to carry a service name, the patch that swaps the agent's own log driver forawslogs, and thatawslogscontainers are out of scope.Tests
Related: https://github.com/SigNoz/platform-pod/issues/1973