Couldn't parse PEM in ../tls/ca.pem file
iam-meghana opened this issue · 2 comments
Looks like there are no certificates written into the /tls directory but the terraform.tfstate has a few different certificates present. I copied the ca_cert into a separate file called ca.pem in /tls directory. And then tried
$ export VAULT_CAPATH="$(cd ../ && pwd)/tls/ca.pem"
(also set the VAULT_ADDR and VAULT_TOKEN)
When I try to connect to vault server,
I get the error
failed to read environment: Error loading CA Path: Couldn't parse PEM in: /terraform_scripts/vault-setup/tls/ca.pem
Any help would be appreciated! Thank you! This project has been very helpful!
It will be hard to help you debug this issue without seeing the content of the PEM you are referring to, however, I can tell you that when specifying a CA file, you should use VAULT_CACERT
not VAULT_CAPATH
. It might be trying to interpret that pem file as a directory.
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days