Class SesConfig


public class SesConfig extends AbstractServiceConfig<SesConfig.Builder>
Configuration for SES-specific container settings.

Instances are created via SesConfig.Builder:


 SesConfig config = SesConfig.builder()
     .smtpHost("localhost")
     .smtpPort(587)
     .smtpUser("user")
     .smtpPass("pass")
     .smtpStarttls("REQUIRED")
     .build();
 
  • Method Details

    • builder

      public static SesConfig.Builder builder()
      Returns a new SesConfig.Builder for this configuration.
      Returns:
      a new builder
    • toBuilder

      public SesConfig.Builder toBuilder()
      Returns a new SesConfig.Builder for this configuration, initialized with the current values of this instance.
      Specified by:
      toBuilder in class AbstractServiceConfig<SesConfig.Builder>
      Returns:
      a new builder pre-populated with this configuration's values
    • getSmtpHost

      public String getSmtpHost()
      Returns the SMTP server host for email relay, or null if relay is disabled.
      Returns:
      the SMTP host, or null
    • getSmtpPort

      public int getSmtpPort()
      Returns the SMTP server port.
      Returns:
      the SMTP port
    • getSmtpUser

      public String getSmtpUser()
      Returns the SMTP authentication username, or null if no authentication.
      Returns:
      the SMTP username, or null
    • getSmtpPass

      public String getSmtpPass()
      Returns the SMTP authentication password, or null.
      Returns:
      the SMTP password, or null
    • getSmtpStarttls

      public String getSmtpStarttls()
      Returns the STARTTLS mode: DISABLED, OPTIONAL, or REQUIRED.
      Returns:
      the STARTTLS mode
    • applyEnvVarsToContainer

      public void applyEnvVarsToContainer(org.testcontainers.containers.Container<?> container)
      Description copied from class: AbstractServiceConfig
      Applies this service configuration to the given container by setting the appropriate environment variables.
      Overrides:
      applyEnvVarsToContainer in class AbstractServiceConfig<SesConfig.Builder>
      Parameters:
      container - the container to configure