Class LinuxParametersProps.Builder

java.lang.Object
software.amazon.awscdk.services.ecs.LinuxParametersProps.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<LinuxParametersProps>
Enclosing interface:
LinuxParametersProps

@Stability(Stable) public static final class LinuxParametersProps.Builder extends Object implements software.amazon.jsii.Builder<LinuxParametersProps>
A builder for LinuxParametersProps
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • initProcessEnabled

      @Stability(Stable) public LinuxParametersProps.Builder initProcessEnabled(Boolean initProcessEnabled)
      Parameters:
      initProcessEnabled - Specifies whether to run an init process inside the container that forwards signals and reaps processes.
      Returns:
      this
    • maxSwap

      @Stability(Stable) public LinuxParametersProps.Builder maxSwap(Size maxSwap)
      Parameters:
      maxSwap - The total amount of swap memory a container can use. This parameter will be translated to the --memory-swap option to docker run.

      This parameter is only supported when you are using the EC2 launch type. Accepted values are positive integers.

      Returns:
      this
    • sharedMemorySize

      @Stability(Stable) public LinuxParametersProps.Builder sharedMemorySize(Number sharedMemorySize)
      Parameters:
      sharedMemorySize - The value for the size of the /dev/shm volume.
      Returns:
      this
    • swappiness

      @Stability(Stable) public LinuxParametersProps.Builder swappiness(Number swappiness)
      Parameters:
      swappiness - This allows you to tune a container's memory swappiness behavior. This parameter maps to the --memory-swappiness option to docker run. The swappiness relates to the kernel's tendency to swap memory. A value of 0 will cause swapping to not happen unless absolutely necessary. A value of 100 will cause pages to be swapped very aggressively.

      This parameter is only supported when you are using the EC2 launch type. Accepted values are whole numbers between 0 and 100. If a value is not specified for maxSwap then this parameter is ignored.

      Returns:
      this
    • build

      @Stability(Stable) public LinuxParametersProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<LinuxParametersProps>
      Returns:
      a new instance of LinuxParametersProps
      Throws:
      NullPointerException - if any required attribute was not provided