'How to pull correct mysql from testcontainer using Quarkus

I using testcontainer and macbook m1. When i start testContainer it thow me error:

Could not pull image: no matching manifest for linux/arm64/v8 in the manifest list entries

I can't understand why because when i using postgres it ok.

Here is my config. Please help

open class MySqlResourceTest : QuarkusTestResourceLifecycleManager {
    private val DATABASE: SpecifiedMySQLContainer = SpecifiedMySQLContainer("mysql:5.7.8").apply {
        withDatabaseName("test")
        withUsername("abc")
        withPassword("123456")
        withExposedPorts(3317)
    }

    override fun start(): MutableMap<String, String> {
        DATABASE.start()
        DATABASE.setCommand()
        return Collections.singletonMap("quarkus.datasource.url", DATABASE.jdbcUrl)
    }

    override fun stop() {
        DATABASE.stop()
    }
}


Solution 1:[1]

Common testcontainer for MySql is org.testcontainers.containers.MySQLContainer. You're using a SpecifiedMySQLContainer in your code snippet, which may cause the issue.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Arno