Skip to content

Conversation

@Mathew-Estafanous
Copy link
Contributor

@Mathew-Estafanous Mathew-Estafanous commented Nov 6, 2025

What does this PR do?

Adds readOnlyRootFilesystem support for the datadog-agent sidecar container and added an init container, named init-volume, that copies /etc/datadog-agent config files to a writeable volume. This named volume is then attached to datadog-agent sidecar as a writable volume

Motivation

Read-only root filesystems (ROFS) have become a standard security measure when running containerized apps and it is important that Datadog keeps up with the latest security measures. Supporting ROFS out-of-the-box ensures customers deploying the Agent with the 'ecs-datadog' terraform module continue to keep up with security standards without any extra work from them.

Describe how you validated your changes

  1. terraform apply'd + ran task definition as a service validating the agent works as expected.
image image
  1. unit tests ✅

Additional Notes

  • Agent ROFS support in container environments RFC

@Mathew-Estafanous Mathew-Estafanous self-assigned this Nov 6, 2025
@Mathew-Estafanous Mathew-Estafanous added the enhancement New feature or request label Nov 6, 2025
@Mathew-Estafanous Mathew-Estafanous marked this pull request as ready for review November 6, 2025 16:27
@Mathew-Estafanous Mathew-Estafanous requested a review from a team as a code owner November 6, 2025 16:27
s.NoError(err, "Failed to parse container definitions")
s.Equal(6, len(containers), "Expected 6 containers in the task definition")
s.Equal(7, len(containers), "Expected 6 containers in the task definition")

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add an assertion here that confirms the presence of the relevant volumes and volumeMounts for ROFS?

}
],

dependsOn = local.rofs_agent_depends_on,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already have a dependsOn parameter defined 3 lines below. There likely is some overwriting going on? Can we merge local.rofs_agent_depends_on with local.log_router_dependency

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah didn't see that. Thanks for catching!

@Mathew-Estafanous Mathew-Estafanous force-pushed the mathew.estafanous/rofs branch 2 times, most recently from 8f3871b to 679a1cc Compare November 6, 2025 19:34
@Mathew-Estafanous Mathew-Estafanous merged commit c255688 into main Nov 12, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants