For AI agents: A markdown version of this page is available at https://docs.datadoghq.com/integrations/amazon-codebuild.md. A documentation index is available at /llms.txt.

AWS CodeBuild

Integration version2.0.0

To find out if this integration is available in your organization, see your Datadog Integrations page or ask your organization administrator.

To initiate an exception request to enable this integration for your organization, email [email protected].

Overview

AWS CodeBuild is a build service that compiles source code, runs tests, and produces software packages that are ready to deploy.

Install the Datadog AWS CodeBuild integration to:

  • Track your builds by project
  • Collect metrics on your builds
  • Correlate builds with the rest of your Datadog metrics

Setup

Installation

If you haven’t already, set up the Amazon Web Services integration first.

Metric collection

  1. In the AWS integration page, ensure that CodeBuild is enabled under the Metric Collection tab.

  2. Install the Datadog - AWS CodeBuild integration.

Log collection

Enable logging

Configure AWS CodeBuild to send logs either to a S3 bucket or to CloudWatch.

Note: If you log to a S3 bucket, make sure that amazon_codebuild is set as Target prefix.

Send logs to Datadog

  1. If you haven’t already, set up the Datadog Forwarder Lambda function.

  2. Once the Lambda function is installed, manually add a trigger on the S3 bucket or CloudWatch log group that contains your AWS CodeBuild logs in the AWS console:

Data Collected

Metrics

aws.codebuild.build_duration
(gauge)
The elapsed time of the build’s BUILD phase.
Shown as second
aws.codebuild.builds
(count)
The number of builds triggered.
Shown as build
aws.codebuild.cpuutilized
(gauge)
The number of CPU units used by the build container.
Shown as core
aws.codebuild.cpuutilized_percent
(gauge)
The percentage of CPU units used by the build container.
Shown as percent
aws.codebuild.download_source_duration
(gauge)
The elapsed time of the build’s DOWNLOAD_SOURCE phase.
Shown as second
aws.codebuild.duration
(gauge)
The elapsed time of all builds.
Shown as second
aws.codebuild.duration.maximum
(gauge)
The maximum elapsed time across all builds.
Shown as second
aws.codebuild.duration.minimum
(gauge)
The minimum elapsed time across all builds.
Shown as second
aws.codebuild.failed_builds
(count)
The number of builds that failed due to client error or timeout.
Shown as build
aws.codebuild.finalizing_duration
(gauge)
The elapsed time of the build’s FINALIZING phase.
Shown as second
aws.codebuild.initialized_duration
(gauge)
The elapsed time of the build’s INITIALIZED phase.
Shown as second
aws.codebuild.install_duration
(gauge)
The elapsed time of the build’s INSTALL phase.
Shown as second
aws.codebuild.memory_utilized
(gauge)
The number of megabytes of memory used by the build container.
Shown as megabyte
aws.codebuild.memory_utilized_percent
(gauge)
The percentage of memory used by the build container.
Shown as percent
aws.codebuild.post_build_duration
(gauge)
The elapsed time of the build’s POST_BUILD phase.
Shown as second
aws.codebuild.pre_build_duration
(gauge)
The elapsed time of the build’s PRE_BUILD phase.
Shown as second
aws.codebuild.provisioning_duration
(gauge)
The elapsed time of the build’s PROVISIONING phase.
Shown as second
aws.codebuild.queued_duration
(gauge)
The elapsed time of the build’s QUEUED phase.
Shown as second
aws.codebuild.storage_read_bytes
(gauge)
The storage read throughput of the build container.
Shown as byte
aws.codebuild.storage_write_bytes
(gauge)
The storage write throughput of the build container.
Shown as byte
aws.codebuild.submitted_duration
(gauge)
The elapsed time of the build’s SUBMITTED phase.
Shown as second
aws.codebuild.succeeded_builds
(count)
The number of successful builds.
Shown as build
aws.codebuild.upload_artifacts_duration
(gauge)
The elapsed time of the build’s UPLOAD_ARTIFACTS phase.
Shown as second

Events

The AWS CodeBuild integration does not include any events.

Service Checks

The AWS CodeBuild integration does not include any service checks.

Troubleshooting

Need help? Contact Datadog support.