Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Root cause of a not working container runtime strategy is not logged #661

Open
gabor-s opened this issue Oct 24, 2023 · 0 comments
Open
Labels
enhancement New feature or request

Comments

@gabor-s
Copy link

gabor-s commented Oct 24, 2023

Expected Behaviour
If a container runtime strategy does not work I would expect the root cause to be logged.

Actual Behaviour
You get a message that the container runtime strategy does not work, but the real error is swallowed.

Testcontainer Logs
Container runtime strategy UnixSocketStrategy does not work

Steps to Reproduce
Using a Docker runtime remove your user from the docker group.

Environment Information

  • Operating System: OpenSUSE Leap 15.5
  • Docker Version: 24.0.5-ce, build a61e2b4c9
  • Node version: v20.8.1
  • Testcontainers version: 10.2.1

I tried to use Testcontainers with Docker runtime, but got the message Container runtime strategy UnixSocketStrategy does not work. I checked the source code and realized that the root cause is not logged, not even catched. So I modified the code locally to catch and log the error. It was connect EACCES /var/run/docker.sock and caused by that my user was not part of the docker group.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants