updated logic to properly detect GPG_KEYDIR path

This commit is contained in:
Christer Edwards 2015-06-01 19:49:01 -06:00 committed by rallytime
parent bc9750b85e
commit 6afb344fe3

View file

@ -108,7 +108,11 @@ LOG = logging.getLogger(__name__)
GPG_BINARY = salt.utils.which('gpg')
GPG_HEADER = re.compile(r'-----BEGIN PGP MESSAGE-----')
DEFAULT_GPG_KEYDIR = os.path.join(salt.syspaths.CONFIG_DIR, 'gpgkeys')
if __salt__['config.get']('gpg_keydir'):
DEFAULT_GPG_KEYDIR = __salt__['config.get']('gpg_keydir')
else:
DEFAULT_GPG_KEYDIR = os.path.join(salt.syspaths.CONFIG_DIR, 'gpgkeys')
def _decrypt_ciphertext(cipher):