Class ElbV2Config
java.lang.Object
io.floci.testcontainers.config.services.AbstractServiceConfig<ElbV2Config.Builder>
io.floci.testcontainers.config.services.ElbV2Config
Configuration for ELBv2 (Elastic Load Balancing v2)-specific container settings.
Instances are created via ElbV2Config.Builder:
ElbV2Config config = ElbV2Config.builder()
.listenerPort(8080)
.build();
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class io.floci.testcontainers.config.services.AbstractServiceConfig
DEFAULT_ENABLED -
Method Summary
Modifier and TypeMethodDescriptionvoidapplyEnvVarsToContainer(org.testcontainers.containers.Container<?> container) Applies this service configuration to the given container by setting the appropriate environment variables.voidapplyExposedPortsToContainer(org.testcontainers.containers.Container<?> container) Applies this service configuration to the given container by exposing the appropriate ports.static ElbV2Config.Builderbuilder()Returns a newElbV2Config.Builderfor this configuration.Returns the pre-declared listener ports to be exposed on the container.booleanisMock()Returns whether load balancers are simulated without starting a real load balancerReturns a newElbV2Config.Builderfor this configuration, initialized with the current values of this instance.Methods inherited from class io.floci.testcontainers.config.services.AbstractServiceConfig
isEnabled
-
Method Details
-
builder
Returns a newElbV2Config.Builderfor this configuration.- Returns:
- a new builder
-
toBuilder
Returns a newElbV2Config.Builderfor this configuration, initialized with the current values of this instance.- Specified by:
toBuilderin classAbstractServiceConfig<ElbV2Config.Builder>- Returns:
- a new builder pre-populated with this configuration's values
-
isMock
public boolean isMock()Returns whether load balancers are simulated without starting a real load balancer- Returns:
trueif mock mode is enabled
-
getListenerPorts
Returns the pre-declared listener ports to be exposed on the container.- Returns:
- immutable list of listener ports
-
applyExposedPortsToContainer
public void applyExposedPortsToContainer(org.testcontainers.containers.Container<?> container) Description copied from class:AbstractServiceConfigApplies this service configuration to the given container by exposing the appropriate ports.- Overrides:
applyExposedPortsToContainerin classAbstractServiceConfig<ElbV2Config.Builder>- Parameters:
container- the container to configure
-
applyEnvVarsToContainer
public void applyEnvVarsToContainer(org.testcontainers.containers.Container<?> container) Description copied from class:AbstractServiceConfigApplies this service configuration to the given container by setting the appropriate environment variables.- Overrides:
applyEnvVarsToContainerin classAbstractServiceConfig<ElbV2Config.Builder>- Parameters:
container- the container to configure
-