etcd-io / etcd

Distributed reliable key-value store for the most critical data of a distributed system
https://etcd.io
Apache License 2.0
47.83k stars 9.77k forks source link

Client cert authentication failure #11344

Closed svopentext closed 4 years ago

svopentext commented 5 years ago

When I am trying to user etcd3 for terraform backend and install client cert, I am getting following error. embed: rejected connection from "10.100.100.10:61282" (error "tls: first record does not look like a TLS handshake", ServerName "")

Here are my etcd details. etcd Version: 3.4.1 Go Version: go1.12.9 Go OS/Arch: linux/amd64 Using docker Docker version 18.03.0-ce, build 0520e24

when I curl, curl --cacert ca.crt --cert client.pem --key client-key.pem https://10.100.10.11:2379 -v

svopentext commented 4 years ago

resolved this issue ..Terrafrom needs all .pem certs terraform { backend "etcdv3" { endpoints = ["10.100.10.00:2379", "110.100.11:2379", "10.100.12:2379"] lock = true prefix = "at4d-terraform-state/" cacert_path = "certs/ca.pem" cert_path = "certs/client.pem" key_path = "certs/client-key.pem" } }