Enum HostKernel
- All Implemented Interfaces:
Serializable,Comparable<HostKernel>,java.lang.constant.Constable
@Generated(value="jsii-pacmak/1.140.0 (build 79fd58c)",
date="2026-09-25T13:53:46.599Z")
@Stability(Stable)
public enum HostKernel
extends Enum<HostKernel>
The host operating system kernel used for builds in a CodeBuild project.
The host kernel does not affect the build environment operating system, which is determined by the build image.
Only applies to the LINUX_CONTAINER, ARM_CONTAINER, LINUX_EC2 and ARM_EC2
environment types. It is not applicable to Windows, Lambda or Mac environment types.
Example:
Project.Builder.create(this, "Project")
.environment(BuildEnvironment.builder()
.buildImage(LinuxBuildImage.STANDARD_7_0)
.hostKernel(HostKernel.LINUX_KERNEL_6)
.build())
.build();
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionRuns on an Amazon Linux 2 host (kernel 4.x).Runs on an Amazon Linux 2023 host (kernel 6.x).Runs on the latest supported host kernel. -
Method Summary
Modifier and TypeMethodDescriptionstatic HostKernelReturns the enum constant of this type with the specified name.static HostKernel[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
LINUX_KERNEL_4
Runs on an Amazon Linux 2 host (kernel 4.x). -
LINUX_KERNEL_6
Runs on an Amazon Linux 2023 host (kernel 6.x). -
LINUX_KERNEL_LATEST
Runs on the latest supported host kernel.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-