mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Use 'config_dir' setting instead of CONFIG_DIR in gpg renderer
This change makes it possible for --config-dir to work from the CLI. Fixes #34037
This commit is contained in:
parent
56c7267631
commit
c4c037d600
1 changed files with 8 additions and 4 deletions
|
@ -123,10 +123,14 @@ def _get_key_dir():
|
|||
'''
|
||||
return the location of the GPG key directory
|
||||
'''
|
||||
if __salt__['config.get']('gpg_keydir'):
|
||||
return __salt__['config.get']('gpg_keydir')
|
||||
else:
|
||||
return os.path.join(salt.syspaths.CONFIG_DIR, 'gpgkeys')
|
||||
key_dir = __salt__['config.get']('gpg_keydir')
|
||||
if not key_dir:
|
||||
key_dir = os.path.join(
|
||||
__salt__['config.get']('config_dir'),
|
||||
'gpgkeys'
|
||||
)
|
||||
|
||||
return key_dir
|
||||
|
||||
|
||||
def _decrypt_ciphertext(cipher):
|
||||
|
|
Loading…
Add table
Reference in a new issue