datadog-ecs-cdk
v1.5.0
Published
Docs: https://isotoma.github.io/datadog-ecs-cdk/
Downloads
362
Readme
datadog-ecs-cdk
Docs: https://isotoma.github.io/datadog-ecs-cdk/
NPM: https://www.npmjs.com/package/datadog-ecs-cdk
Source: https://github.com/isotoma/datadog-ecs-cdk
EC2 example
import { DatadogEcsDaemonService } from 'datadog-ecs-cdk';
// ...
new DatadogEcsDaemonService(this, 'EcsDatadog', {
ecsCluster: myCluster,
datadogApiKeySecret: ecs.Secret.fromSecretsManager(mySecret),
// By default, when logs are enabled, collects logs from all containers,
// but not the Datadog agent container itself.
logs: {
enabled: true,
},
});
Fargate example
import { addDatadogToFargateTask } from 'datadog-ecs-cdk';
// ...
const myTaskDef = ...
addDatadogToFargateTask(myTaskDef, {
datadogApiKeySecret: ecs.Secret.fromSecretsManager(mySecret),
agent: {
enabled: true,
statsd: {
enabled: true,
},
},
fireLensLogging: {
enabled: true,
service: 'myservice',
source: 'myservice',
},
});