Class JournaldLogDriver.Builder

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

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

    • create

      @Stability(Stable) public static JournaldLogDriver.Builder create()
      Returns:
      a new instance of JournaldLogDriver.Builder.
    • env

      @Stability(Stable) public JournaldLogDriver.Builder env(List<String> env)
      The env option takes an array of keys.

      If there is collision between label and env keys, the value of the env takes precedence. Adds additional fields to the extra attributes of a logging message.

      Default: - No env

      Parameters:
      env - The env option takes an array of keys. This parameter is required.
      Returns:
      this
    • envRegex

      @Stability(Stable) public JournaldLogDriver.Builder envRegex(String envRegex)
      The env-regex option is similar to and compatible with env.

      Its value is a regular expression to match logging-related environment variables. It is used for advanced log tag options.

      Default: - No envRegex

      Parameters:
      envRegex - The env-regex option is similar to and compatible with env. This parameter is required.
      Returns:
      this
    • labels

      @Stability(Stable) public JournaldLogDriver.Builder labels(List<String> labels)
      The labels option takes an array of keys.

      If there is collision between label and env keys, the value of the env takes precedence. Adds additional fields to the extra attributes of a logging message.

      Default: - No labels

      Parameters:
      labels - The labels option takes an array of keys. This parameter is required.
      Returns:
      this
    • tag

      @Stability(Stable) public JournaldLogDriver.Builder tag(String tag)
      By default, Docker uses the first 12 characters of the container ID to tag log messages.

      Refer to the log tag option documentation for customizing the log tag format.

      Default: - The first 12 characters of the container ID

      Parameters:
      tag - By default, Docker uses the first 12 characters of the container ID to tag log messages. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public JournaldLogDriver build()
      Specified by:
      build in interface software.amazon.jsii.Builder<JournaldLogDriver>
      Returns:
      a newly built instance of JournaldLogDriver.