Build machine compute type.
Namespace: Amazon.CDK.AWS.CodeBuild
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
Syntax (vb)
Examples
Vpc vpc;
SecurityGroup mySecurityGroup;
new CodeBuildStep("Synth", new CodeBuildStepProps {
// ...standard ShellStep props...
Commands = new [] { },
Env = new Dictionary<string, object> { },
// If you are using a CodeBuildStep explicitly, set the 'cdk.out' directory
// to be the synth step's output.
PrimaryOutputDirectory = "cdk.out",
// Control the name of the project
ProjectName = "MyProject",
// Control parts of the BuildSpec other than the regular 'build' and 'install' commands
PartialBuildSpec = BuildSpec.FromObject(new Dictionary<string, object> {
{ "version", "0.2" }
}),
// Control the build environment
BuildEnvironment = new BuildEnvironment {
ComputeType = ComputeType.LARGE,
Privileged = true,
DockerServer = new DockerServerOptions {
ComputeType = DockerServerComputeType.SMALL,
SecurityGroups = new [] { mySecurityGroup }
}
},
Timeout = Duration.Minutes(90),
FileSystemLocations = new [] { FileSystemLocation.Efs(new EfsFileSystemLocationProps {
Identifier = "myidentifier2",
Location = "myclodation.mydnsroot.com:/loc",
MountPoint = "/media",
MountOptions = "opts"
}) },
// Control Elastic Network Interface creation
Vpc = vpc,
SubnetSelection = new SubnetSelection { SubnetType = SubnetType.PRIVATE_WITH_EGRESS },
SecurityGroups = new [] { mySecurityGroup },
// Control caching
Cache = Cache.Bucket(new Bucket(this, "Cache")),
// Additional policy statements for the execution role
RolePolicyStatements = new [] {
new PolicyStatement(new PolicyStatementProps { }) }
});
Synopsis
Fields
| ATTRIBUTE_BASED | Build machine compute type. |
| CUSTOM_INSTANCE_TYPE | Build machine compute type. |
| LAMBDA_10GB | Build machine compute type. |
| LAMBDA_1GB | Build machine compute type. |
| LAMBDA_2GB | Build machine compute type. |
| LAMBDA_4GB | Build machine compute type. |
| LAMBDA_8GB | Build machine compute type. |
| LARGE | Build machine compute type. |
| MEDIUM | Build machine compute type. |
| SMALL | Build machine compute type. |
| X2_LARGE | Build machine compute type. |
| X_LARGE | Build machine compute type. |
Fields
| Name | Description |
|---|---|
| ATTRIBUTE_BASED | Build machine compute type. |
| CUSTOM_INSTANCE_TYPE | Build machine compute type. |
| LAMBDA_10GB | Build machine compute type. |
| LAMBDA_1GB | Build machine compute type. |
| LAMBDA_2GB | Build machine compute type. |
| LAMBDA_4GB | Build machine compute type. |
| LAMBDA_8GB | Build machine compute type. |
| LARGE | Build machine compute type. |
| MEDIUM | Build machine compute type. |
| SMALL | Build machine compute type. |
| X2_LARGE | Build machine compute type. |
| X_LARGE | Build machine compute type. |