- version: Required mapping. Represents the build spec version. We recommend you use 0.2.
- env: Optional sequence. Represents information for one or more custom environment variables.
- phases: Required sequence. Represents the commands AWS CodeBuild will run during each phase of the build.
- artifacts: Optional sequence. Represents information about where AWS CodeBuild can find the build output and
how AWS CodeBuild will prepare it for uploading to the Amazon S3 output bucket.
- files: Required sequence. Represents the locations containing the build output artifacts in the build environment.
- discard-paths: Optional mapping. Represents whether paths to files in the build output artifact are discarded
- base-directory: Optional mapping. Represents one or more top-level directories.
- cache Optional sequence. Represents information about where AWS CodeBuild can prepare the files for uploading cache to an Amazon S3 cache bucket.
Futher reading: