fix: Use the actual Docker endpoint to extract the socket path for the Resource Reaper #930
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Instead of relying on the automatically discovered Docker endpoint to retrieve the Docker socket, the pull request utilizes the actual Docker endpoint. If the auto-discovery mechanism fails to detect a Docker endpoint and the user manually configures the Docker endpoint using the builder API, Testcontainers will encounter a null reference exception during runtime.
Why is it important?
The fix is significant because it allows the support of test environments where the auto-discovery mechanism cannot detect a Docker endpoint (although this is not recommended).
Related issues
How to test this PR
@paule96 Would it be possible for you to test the fix and see if it resolves the issue? It is a bit challenging to set up a test in CI due to the required remote Docker endpoint, etc.