`bosh` gives me a `x509: cannot validate certificate` — how do I fix?

706 Views Asked by At

When I try to set my BOSH environment, I get an x509 error:

$ bosh env 192.168.50.4 lite
Fetching info:
  Performing request GET 'https://192.168.50.4:25555/info':
    Performing GET request:
      Get https://192.168.50.4:25555/info: x509: certificate signed by unknown authority

Exit code 1
2

There are 2 best solutions below

0
On

Consider that the wildcard("*") often won't recognize points("."). A CN like "first.example.com" is masked as "*.example.com", not "*example.com".

Your newest edit seems to indicate that the certification chain is not imported.

0
On

Looks like there is a --ca-cert <cert_name) option you can set: https://github.com/cloudfoundry/cf-deployment/issues/170

Example: bosh -e MYDIRECTORIPADDRESS --ca-cert <(bbl director-ca-cert) deploy ...