-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Description
When I start a new MySql container I set a diferent command, but this is override per the method "configure()"
My code:
(MySQLContainer) new MySQLContainer()
.withDatabaseName("f"+timeStamp)
.withUsername("f"+timeStamp)
.withPassword("f"+timeStamp)
.withCommand("mysqld", "--lower_case_table_names=1")
.withLogConsumer(new Slf4jLogConsumer(logger));The code of MYSQLContainer:
@Override
protected void configure() {
optionallyMapResourceParameterAsVolume(MY_CNF_CONFIG_OVERRIDE_PARAM_NAME, "/etc/mysql/conf.d", "mysql-default-conf");
addExposedPort(3306);
addEnv("MYSQL_DATABASE", databaseName);
addEnv("MYSQL_USER", username);
addEnv("MYSQL_PASSWORD", password);
addEnv("MYSQL_ROOT_PASSWORD", "test");
setCommand("mysqld");
setStartupAttempts(3);
}I need this to support case insentive. Do you know athoner way to do this? If not I can fix and open PR.
Another option is add lower_case_table_names=1" in the file my.cnf Or have
a way to add more configurations in the file.
Many thanks.
Metadata
Metadata
Assignees
Labels
No labels