interface ComputeConfiguration
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.CodeBuild.ComputeConfiguration |
![]() | github.com/aws/aws-cdk-go/awscdk/v2/awscodebuild#ComputeConfiguration |
![]() | software.amazon.awscdk.services.codebuild.ComputeConfiguration |
![]() | aws_cdk.aws_codebuild.ComputeConfiguration |
![]() | aws-cdk-lib » aws_codebuild » ComputeConfiguration |
The compute configuration for the fleet.
Despite what the CloudFormation schema says, the numeric properties (disk, memory, vCpu) are not optional.
An undefined
value will cause the CloudFormation deployment to fail, e.g.
Cannot invoke "java.lang.Integer.intValue()" because the return value of "software.amazon.codebuild.fleet.ComputeConfiguration.getMemory()" is null Therefore, these properties default value is set to 0.
Example
import { Size } from 'aws-cdk-lib';
const fleet = new codebuild.Fleet(this, 'MyFleet', {
baseCapacity: 1,
computeType: codebuild.FleetComputeType.ATTRIBUTE_BASED,
environmentType: codebuild.EnvironmentType.LINUX_CONTAINER,
computeConfiguration: {
vCpu: 2,
memory: Size.gibibytes(4),
disk: Size.gibibytes(10),
machineType: codebuild.MachineType.GENERAL,
},
});
Properties
Name | Type | Description |
---|---|---|
disk? | Size | The amount of disk space of the instance type included in your fleet. |
machine | Machine | The machine type of the instance type included in your fleet. |
memory? | Size | The amount of memory of the instance type included in your fleet. |
v | number | The number of vCPUs of the instance type included in your fleet. |
disk?
Type:
Size
(optional, default: No requirement, the actual value will be based on the other selected configuration properties)
The amount of disk space of the instance type included in your fleet.
machineType?
Type:
Machine
(optional, default: No requirement, the actual value will be based on the other selected configuration properties)
The machine type of the instance type included in your fleet.
memory?
Type:
Size
(optional, default: No requirement, the actual value will be based on the other selected configuration properties)
The amount of memory of the instance type included in your fleet.
vCpu?
Type:
number
(optional, default: No requirement, the actual value will be based on the other selected configuration properties)
The number of vCPUs of the instance type included in your fleet.