Skip to content

"Could not find a working container runtime strategy" when starting MySqlContainer in node inside a container #793

Description

@tizueh

Expected Behaviour
Testcontainers to be able to start a MySqlContainer without problem.

Actual Behaviour
It shows the error "Could not find a working container runtime strategy".

Testcontainer Logs
Error: Could not find a working container runtime strategy
|
| 12 |
| 13 | // Test non-root user
| > 14 | const container = await new MySqlContainer()
| | ^
| 15 | .withUsername(username)
| 16 | .withUserPassword(password)
| 17 | .withDatabase(database)
|
| at getContainerRuntimeClient (/app/node_modules/testcontainers/src/container-runtime/clients/client.ts:61:9)
| at MySqlContainer.start (/app/node_modules/testcontainers/src/generic-container/generic-container.ts:81:20)
| at MySqlContainer.start (/app/node_modules/@testcontainers/mysql/src/mysql-container.ts:44:7)
| at /app/src/index.test.ts:14:21

Steps to Reproduce

  1. clone https://github.com/timonkrebs/docker-express-react-playwright/tree/testcontainers
  2. run it with act act pull_request
  3. Error: Could not find a working container runtime strategy

Environment Information

  • Operating System: WSL2
  • Docker Version: 4.19.0 (106363)
  • Node version: v20.15.0
  • Testcontainers version: "@testcontainers/mysql": "^10.10.0"

Metadata

Metadata

Assignees

No one assigned

    Labels

    triageInvestigation required

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions