From eaab76901aa127e59d90973258fe853396066efa Mon Sep 17 00:00:00 2001 From: Patrick de Ruiter Date: Tue, 18 Nov 2025 03:56:41 +0100 Subject: [PATCH] fix: Change Docker provider from TCP to SSH connection Updated Docker provider configuration: - Changed from tcp://192.168.2.170:2376 to ssh://ansible@wbyc-srv-docker01.bsdserver.lan:22 - Added ssh_opts with path to SSH key and StrictHostKeyChecking=no - Removed cert_path configuration (not needed for SSH) This matches the working configuration from terraform-docker-eda module and uses the SSH key retrieved from Vault via setup-ssh.sh script. --- provider.tf | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/provider.tf b/provider.tf index 8da8d2a..b890e50 100644 --- a/provider.tf +++ b/provider.tf @@ -29,11 +29,9 @@ provider "dns" { # Configure the Docker Provider provider "docker" { - host = "tcp://192.168.2.170:2376" + host = "ssh://ansible@wbyc-srv-docker01.bsdserver.lan:22" - # Use cert_path only if certificates exist (local development) - # For CI/CD, use DOCKER_HOST environment variable instead - cert_path = fileexists(pathexpand("~/.docker/ca.pem")) ? pathexpand("~/.docker") : null + ssh_opts = ["-i", "${path.module}/.ssh/id_rsa", "-o", "StrictHostKeyChecking=no"] } # Configure the Vault Provider