-
Notifications
You must be signed in to change notification settings - Fork 148
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
load obsoleted gpg keys from gpg-signatures.json
- Loading branch information
Showing
5 changed files
with
39 additions
and
14 deletions.
There are no files selected for viewing
16 changes: 4 additions & 12 deletions
16
.../system_upgrade/common/actors/removeobsoletegpgkeys/libraries/removeobsoleterpmgpgkeys.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,6 @@ | |
"24c6a8a7f4a80eb5", | ||
"05b555b38483c65d", | ||
"4eb84e71f2ee9d55" | ||
] | ||
], | ||
"obsoleted-keys": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import json | ||
import os | ||
|
||
from leapp.exceptions import StopActorExecutionError | ||
from leapp.libraries.stdlib import api | ||
|
||
|
||
def get_distribution_data(distribution): | ||
distributions_path = api.get_common_folder_path('distro') | ||
|
||
distribution_config = os.path.join(distributions_path, distribution, 'gpg-signatures.json') | ||
if os.path.exists(distribution_config): | ||
with open(distribution_config) as distro_config_file: | ||
return json.load(distro_config_file) | ||
else: | ||
raise StopActorExecutionError( | ||
'Cannot find distribution signature configuration.', | ||
details={'Problem': 'Distribution {} was not found in {}.'.format(distribution, distributions_path)}) |