Use os.path.join to return full path to ca bundle

Fixes #29202
This commit is contained in:
Loren Gordon 2015-11-25 13:34:44 -05:00
parent a26c10a811
commit b1dae5e6fe

View file

@ -467,8 +467,9 @@ def get_ca_bundle(opts=None):
# Check Salt first
for salt_root in file_roots.get('base', []):
for path in ('cacert.pem', 'ca-bundle.crt'):
if os.path.exists(path):
return path
cert_path = os.path.join(salt_root, path)
if os.path.exists(cert_path):
return cert_path
locations = (
# Debian has paths that often exist on other distros