I try to connect to docker engine api using Docker.DotNet client.
Docker is installed on Windows 10.
Connection using named pipeline "npipe://./pipe/docker_engine" is working, also connection using "tcp://localhost:2375" (With enabled option: Expose daemon on tcp://localhost:2375 without TLS) but I am confused with secure connection option.
Documentation is clear:
var credentials = new CertificateCredentials (new X509Certificate2 ("CertFile", "Password")); var config = new DockerClientConfiguration("http://ubuntu-docker.cloudapp.net:4243", credentials); DockerClient client = config.CreateClient();
But based on code and documentation, what is not clear and please answer my questions:
- How to register certificate that should be used by docker?
- How to specify that only secure connection is allowed?
- How to specify port which should be used?
Could you please provide exact steps, how to install and configure docker to reach secure remote connection?
Source: Docker Questions