testcontainers-dotnet icon indicating copy to clipboard operation
testcontainers-dotnet copied to clipboard

[Enhancement]: Instead of fixed to docker, I wish a independent container hosting implementation like kubernetes

Open codingbott opened this issue 4 months ago • 2 comments

Problem

Currently I have to use docker or test containers cloud to run test containers.

Because of company policy I'm not allowed to used any local subsystem like wsl or docker desktop.

I have some remote docker server, but by company policy I have to use docker.api over ssh which the nuget docker lib not supporting. (btw. I have a fork which enables this. I saw you have a fork, too. maybe you like my docker over ssh support)

I'm currently not able to us test containers, with the current implementation.

Solution

Put the container runtime into a strategy pattern and getting independent of docker runtime. find abstractions to be later implemented in different container hostings.

finally implement a k8s client to run test container on remote k8s clusters.

Benefit

flexibility in hosting

Alternatives

don't now, that why i'm asking.

support docker over ssh in the dotnet ssh lib. (with key authentication)

Would you like to help contributing this enhancement?

No

codingbott avatar Aug 13 '25 13:08 codingbott

Thanks for creating the issue. I believe this has been a long requested feature for TC for Java, and it has some history I'd like to share: https://github.com/testcontainers/testcontainers-java/issues/1135#issuecomment-453757407. TC for .NET, like the other language implementations, is Docker Engine API compatible. I simply don't have the time to add native Kubernetes support to the library.

HofmeisterAn avatar Aug 13 '25 16:08 HofmeisterAn

I have some remote docker server, but by company policy I have to use docker.api over ssh which the nuget docker lib not supporting. (btw. I have a fork which enables this. I saw you have a fork, too. maybe you like my docker over ssh support)

@codingbott I think that is a much more reasonable path to go down in order to unlock you 👍

kiview avatar Aug 15 '25 15:08 kiview