-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Open
Labels
@aws-cdk/aws-ecsRelated to Amazon Elastic ContainerRelated to Amazon Elastic Containereffort/mediumMedium work item – several days of effortMedium work item – several days of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p2
Description
Describe the feature
While this is not explicitly mentioned in ECS document, we're able to use "none" as log driver for container if we don't want to collect any logs from it.
Use Case
Some infra setups may want to use OpenTelemetry logs sending functionally (collect logs via OTel), so collecting the same logs from the stdout/stderr is not necessary. For such cases, we need the ability to set the none driver for container.
For now, we can do that by escaping to L1 templates with:
const taskDefinition = taskDefinition.node
.defaultChild as ecs.CfnTaskDefinition;
taskDefinition.addPropertyOverride(
"ContainerDefinitions.0.LogConfiguration",
{
LogDriver: "none",
}
);Proposed Solution
add none log driver to LogDriver class similary to already existed options
Other Information
No response
Acknowledgements
- I may be able to implement this feature request
- This feature might incur a breaking change
AWS CDK Library version (aws-cdk-lib)
2.220.0
AWS CDK CLI version
2.1030.0
Environment details (OS name and version, etc.)
macOS 26.0.1
Metadata
Metadata
Assignees
Labels
@aws-cdk/aws-ecsRelated to Amazon Elastic ContainerRelated to Amazon Elastic Containereffort/mediumMedium work item – several days of effortMedium work item – several days of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p2