buildspec

The YAML file that tells CodeBuild which commands to run in each build phase, which variables to set and which artifacts and reports to keep.

In more detail

It has an env block for variables and secrets, phases named install, pre build, build and post build, and sections for artifacts, reports and cache. A failure in an early phase skips straight to the end, while post build still runs after a failed build unless told otherwise. Secrets belong in Parameter Store or Secrets Manager references, never in plain variables.

Related terms

Taught in

References

Certification courses