@nomadblacky/cdk-datadog-resources
Project description
AWS CDK Datadog Resources
An AWS CDK construct library that wraps DataDog/datadog-cloudformation-resources.
Requirements
Before using this library, register datadog-cloudformation-resources to your AWS account.
You need to register the correct version listed in Supported Resources
.
Supported CDK Languages
- TypeScript
- Python
JavaSorry, there is a problem with the release. (#22)
Supported Resources
Supported? | Resource | Datadog CF Resource Name | Description | Datadog CF Version |
---|---|---|---|---|
✅ | Dashboards | Datadog::Dashboards::Dashboard |
Create, update, and delete Datadog dashboards. | 1.0.0 |
✅ | Datadog-AWS integration | Datadog::Integrations::AWS |
Manage your Datadog-Amazon Web Service integration. | 1.1.0 |
✅ | Monitors | Datadog::Monitors::Monitor |
Create, update, and delete Datadog monitors. | 3.0.0 |
✅ | Downtimes | Datadog::Monitors::Downtime |
Enable or disable downtimes for your monitors. | 2.0.0 |
✅ | Users | Datadog::IAM::User |
Create and manage Datadog users. | 1.2.0 |
Installation
TypeScript
npm install @nomadblacky/cdk-datadog-resources
Python
pip install cdk-datadog-resources
Java
<dependency>
<groupId>dev.nomadblacky</groupId>
<artifactId>cdk-datadog-resources</artifactId>
<version>x.y.z</version>
</dependency>
Usage
Below are examples of TypeScript.
Dashboards
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
import fs as fs
from nomadblacky.cdk_datadog_resources import DatadogDashboard
DatadogDashboard(your_stack, "TestDashboard",
datadog_credentials={
"api_key": process.env.DATADOG_API_KEY,
"application_key": process.env.DATADOG_APP_KEY
},
dashboard_definition=fs.read_file_sync(f"{__dirname}/path/to/your/dashboard-definition.json").to_string()
)
Monitors
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
from nomadblacky.cdk_datadog_resources import DatadogMonitor
DatadogMonitor(your_stack, "TestMonitor",
datadog_credentials={
"api_key": process.env.DATADOG_API_KEY,
"application_key": process.env.DATADOG_APP_KEY
},
query="avg(last_1h):sum:system.cpu.system{host:host0} > 100",
type=MonitorType.QueryAlert,
name="Test Monitor",
options={
"thresholds": {
"critical": 100,
"warning": 80,
"o_k": 90
},
"notify_no_data": True,
"evaluation_delay": 60
}
)
Downtimes
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
from nomadblacky.cdk_datadog_resources import DatadogDowntime
DatadogDowntime(stack, "TestMonitor",
datadog_credentials={
"api_key": "DATADOG_API_KEY",
"application_key": "DATADOG_APP_KEY"
},
scope=["host:myserver", "service:myservice"],
start=1624542715,
end=1624546321
)
Users
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
from nomadblacky.cdk_datadog_resources import DatadogIAMUser
DatadogIAMUser(stack, "TestUser",
datadog_credentials={
"api_key": "DATADOG_API_KEY",
"application_key": "DATADOG_APP_KEY"
},
email="jane.doe@example.com",
name="name_example",
handle="title_example",
disabled=False
)
DataDog Integration
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
from nomadblacky.cdk_datadog_resources import DatadogIntegrationAWS
DatadogIntegrationAWS(self, "DataDogIntegration",
datadog_credentials={
"api_key": "DATADOG_API_KEY",
"application_key": "DATADOG_APP_KEY"
},
account_id="ACCOUNT_ID",
role_name="DatadogIntegrationRole"
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for cdk-datadog-resources-0.2.41.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 46eafa4a8ec747d23b7ad9c06682fb2d7f0a96cd3c0a298f67baeda0a2467548 |
|
MD5 | 5bd89465042d4b0b3c105c426288ab37 |
|
BLAKE2b-256 | 719a167549cd83a374f245a4a6da7687ca278900e2b076480da09d777171e74e |
Close
Hashes for cdk_datadog_resources-0.2.41-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09aba0db483cb5517dda94c99d0287c95f880c5c39556c261aa6c5e21d1f76b0 |
|
MD5 | 6128ea258fccb15e5e861cf9383e3c97 |
|
BLAKE2b-256 | b13a2d8f7dab9bfd225b36d27e2d95cc73a1ba1272d8de973958904cbbd494c1 |