Skip to main content

CDK construct library that allows you enable an AWS EKS cluster for CloudWatch Container Insight

Project description

CDK EKS Container Insight

This construct configures the necessary dependencies and installs Amazon CloudWatch Container Insight on an EKS cluster managed by AWS CDK.

Using

In your CDK project, initialize a new Container Insight construct for your EKS cluster, like this:

const cluster = new Cluster(this, 'testCluster', {
  vpc: vpc,
  role: clusterRole,
  version: KubernetesVersion.V1_24,
  kubectlLayer: new KubectlV24Layer(this, 'KubectlLayer'),
  defaultCapacity: 1
});

new ContainerInsight(this, 'ContainerInsight', {
  cluster: cluster,
});

This will install and configure Container Insight on EC2 managed nodes in your cluster.

Testing

This construct adds a custom task to projen, so you can test a full deployment of an EKS cluster with CloudWatch Container Insight installed as specified in test/integ.containerinsight.ts by running the following:

export CDK_DEFAULT_REGION=<aws region>
export CDK_DEFAULT_ACCOUNT=<account id>
npx projen test:deploy

And you can valid the construct installation by login in CloudWatch console to

As the above will create a cluster. And the Container Insight will show your how cluster information in CloudWatch.

You can clean things up by deleting the deployment and the CDK test stack:

npx projen test:destroy

Security

See CONTRIBUTING for more information.

License

This project is licensed under the Apache-2.0 License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cdk-eks-container-insight-0.0.7.tar.gz (468.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cdk_eks_container_insight-0.0.7-py3-none-any.whl (467.4 kB view details)

Uploaded Python 3

File details

Details for the file cdk-eks-container-insight-0.0.7.tar.gz.

File metadata

File hashes

Hashes for cdk-eks-container-insight-0.0.7.tar.gz
Algorithm Hash digest
SHA256 1abe9eaecbbf8efe3b075a3918ca1d09d8a23c3dd993c7580c07d221a5997ca4
MD5 d94c2305b06c4355901e8eeaf0f4e0c6
BLAKE2b-256 da7843d8af74707bd107df70f9cfd8879ab997d1b07378a710733323e8cf208c

See more details on using hashes here.

File details

Details for the file cdk_eks_container_insight-0.0.7-py3-none-any.whl.

File metadata

File hashes

Hashes for cdk_eks_container_insight-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 6e7bb916d0a8a5240ccacbae9aefc88a9056939b69e134eb492e7a466a3acc55
MD5 af25341e79b42842f8a502cf2d224f84
BLAKE2b-256 ae8de2db283acd26722fdb726ed4e49e28c85920872a90c26348a1e292040cd6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page