Package io.ebean.test.containers
Interface ContainerBuilder<C,SELF extends ContainerBuilder<C,SELF>>
- All Known Subinterfaces:
ContainerBuilderDb<C,SELF>
- All Known Implementing Classes:
ClickHouseContainer.Builder,CockroachContainer.Builder,Db2Container.Builder,ElasticContainer.Builder,HanaContainer.Builder,LocalDynamoDBContainer.Builder,Localstack2Container.Builder,LocalstackContainer.Builder,MariaDBContainer.Builder,MySqlContainer.Builder,NuoDBContainer.Builder,OracleContainer.Builder,PostgisContainer.Builder,PostgresContainer.Builder,RedisContainer.Builder,SqlServerContainer.Builder,YugabyteContainer.Builder
public interface ContainerBuilder<C,SELF extends ContainerBuilder<C,SELF>>
Builder for containers.
-
Method Summary
Modifier and TypeMethodDescriptionadminInternalPort(int adminInternalPort) Set the internal port mapped to the admin port.adminPort(int adminPort) Set the exposed admin port to use.build()Build the container.containerName(String containerName) Set the container name to use.Set the docker executable to use.Set the docker image to use.internalPort(int internalPort) Set the internal port to map to.maxReadyAttempts(int maxReadyAttempts) Set the maximum attempts to check ready status.Set a container mirror for images to use with CI builds.port(int port) Set the exposed port to use.properties(Properties properties) Set configuration from properties.shutdownMode(StopMode shutdownHookMode) Set the shutdown hook mode to automatically stop/remove the container on JVM shutdown.start()Build and start the container.Set the start mode.
-
Method Details
-
build
C build()Build the container. -
start
C start()Build and start the container. -
properties
Set configuration from properties. -
mirror
Set a container mirror for images to use with CI builds.For example "my.ecr/mirror".
The mirror is not used when deemed to be running locally. Typically determined via a
~/.ebean/ignore-docker-shutdownfile or alternative marker file set via system propertyebean.test.localDevelopment>. -
containerName
Set the container name to use. -
port
Set the exposed port to use. -
internalPort
Set the internal port to map to. -
adminPort
Set the exposed admin port to use. -
adminInternalPort
Set the internal port mapped to the admin port. -
image
Set the docker image to use. -
maxReadyAttempts
Set the maximum attempts to check ready status. -
docker
Set the docker executable to use. Defaults to docker. -
startMode
Set the start mode. One of create, dropCreate, or container [only]. -
shutdownMode
Set the shutdown hook mode to automatically stop/remove the container on JVM shutdown.
-