diff options
author | Jack Morgan <jack.morgan@intel.com> | 2017-12-18 15:12:15 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-12-18 15:12:15 +0000 |
commit | 771ea333aff9847eb69a5360e64c1779ca1db1df (patch) | |
tree | 810eabefe555475dc1ae97290390410b546f4357 /config/utils | |
parent | b7316b60e93ad4bd9291f36965adbef4a0581eeb (diff) | |
parent | 39fce9a9a2b9197577692072c5f030877c9fc90e (diff) |
Merge "generate_config.py: Fix running without eyaml" into stable/euphrates
Diffstat (limited to 'config/utils')
-rwxr-xr-x | config/utils/generate_config.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/config/utils/generate_config.py b/config/utils/generate_config.py index ba4192cb..37108808 100755 --- a/config/utils/generate_config.py +++ b/config/utils/generate_config.py @@ -57,9 +57,13 @@ ENV.filters['dpkg_arch'] = dpkg_arch try: DICT = yaml.safe_load(check_output(['eyaml', 'decrypt', '-f', ARGS.yaml])) except CalledProcessError as ex: - pass -if not DICT: - logging.warn('PDF decryption failed, fallback to using raw data.') + logging.error('eyaml decryption failed, keys might be missing') +except OSError as ex: + logging.warn('eyaml not found, skipping decryption') +try: + DICT +except NameError as ex: + logging.warn('PDF decryption skipped, fallback to using raw data.') with open(ARGS.yaml) as _: DICT = yaml.safe_load(_) |