mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
pkg build modules throw better exception message if keyid wasn't found
This commit is contained in:
parent
50d417f267
commit
53f2be5b21
2 changed files with 11 additions and 5 deletions
|
@ -604,7 +604,8 @@ def make_repo(repodir,
|
|||
|
||||
except SaltInvocationError:
|
||||
raise SaltInvocationError(
|
||||
'Public and Private key files associated with Pillar data and \'keyid\' {0} could not be found'
|
||||
'Public and Private key files associated with Pillar data and \'keyid\' '
|
||||
'{0} could not be found'
|
||||
.format(keyid)
|
||||
)
|
||||
|
||||
|
@ -619,7 +620,8 @@ def make_repo(repodir,
|
|||
|
||||
if local_keyid is None:
|
||||
raise SaltInvocationError(
|
||||
'\'keyid\' was not found in gpg keyring'
|
||||
'The key ID \'{0}\' was not found in GnuPG keyring at \'{1}\''
|
||||
.format(keyid, gnupghome)
|
||||
)
|
||||
|
||||
_check_repo_sign_utils_support()
|
||||
|
|
|
@ -425,7 +425,8 @@ def make_repo(repodir,
|
|||
|
||||
except SaltInvocationError:
|
||||
raise SaltInvocationError(
|
||||
'Public and Private key files associated with Pillar data and \'keyid\' {0} could not be found'
|
||||
'Public and Private key files associated with Pillar data and \'keyid\' '
|
||||
'{0} could not be found'
|
||||
.format(keyid)
|
||||
)
|
||||
|
||||
|
@ -440,14 +441,17 @@ def make_repo(repodir,
|
|||
|
||||
if local_keyid is None:
|
||||
raise SaltInvocationError(
|
||||
'\'keyid\' was not found in gpg keyring'
|
||||
'The key ID \'{0}\' was not found in GnuPG keyring at \'{1}\''
|
||||
.format(keyid, gnupghome)
|
||||
)
|
||||
|
||||
if use_passphrase:
|
||||
phrase = __salt__['pillar.get']('gpg_passphrase')
|
||||
|
||||
if local_uids:
|
||||
define_gpg_name = '--define=\'%_signature gpg\' --define=\'%_gpg_name {0}\''.format(local_uids[0])
|
||||
define_gpg_name = '--define=\'%_signature gpg\' --define=\'%_gpg_name {0}\''.format(
|
||||
local_uids[0]
|
||||
)
|
||||
|
||||
# need to update rpm with public key
|
||||
cmd = 'rpm --import {0}'.format(pkg_pub_key_file)
|
||||
|
|
Loading…
Add table
Reference in a new issue