Skip to content

How to do mTLS? DOCKER_CONTEXT / DOCKER_CERT_PATH / ~/.testcontainers.properties #1469

Answered by HofmeisterAn
romerod asked this question in Q&A
Discussion options

You must be logged in to vote

Testcontainers checks for container runtimes in the following order and uses the first it can connect to. If mTLS is set up correctly, it should work. These are our tests.

Don't mix custom configurations. Use either env vars or the .testcontainers.properties file. Mixing makes it hard to tell what's used. Try removing the extra context and use just one custom configuration.

Here are a few things you should check:

  • I think $env:DOCKER_TLS_VERIFY=" is a typo.
  • Are your certs in PEM format?
  • Does the docker.cert.path contain the client certificates (or just the directory)?
  • Our test uses the following configuration (note: docker.tls is overridden by docker.tls.verify and gets enabled automatica…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@romerod
Comment options

Answer selected by romerod
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants