]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
Override failing package signature checks
authorNathan Cutler <ncutler@suse.com>
Wed, 30 Aug 2017 09:55:15 +0000 (11:55 +0200)
committerKyr Shatskyy <kyrylo.shatskyy@gmail.com>
Thu, 18 Oct 2018 22:52:44 +0000 (00:52 +0200)
The RPMs built by teuthology's buildpackages task are not signed and
after a recent zypper update the install task started to fail with

File 'repomd.xml' from repository 'ceph-rpm-under-test' is unsigned, continue? [yes/no] (no): no
Error building the cache: [ceph-rpm-under-test|http://149.202.175.91/ceph-rpm-sle12-x86_64-basic/sha1/3804e807353c9d125753b1cf4f6405f79db83d4e/x86_64] Valid metadata not found at specified URL

Signed-off-by: Nathan Cutler <ncutler@suse.com>
teuthology/packaging.py
teuthology/task/install/rpm.py

index 02ff68329e2ea6ecf716a91963ebbf7786788edf..e847fc0f037be1b8f7ab1f0b9a693a2ed66af64c 100644 (file)
@@ -796,7 +796,9 @@ class GitbuilderProject(object):
             url = "{base_url}/{arch}".format(
                 base_url=self.base_url, arch=self.arch)
             self.remote.run(args=[
-                'sudo', 'zypper', '-n', 'addrepo', '-p', '1', url, 'ceph-rpm-under-test'
+                'sudo', 'zypper', '-n', 'addrepo', '-p', '1', url, 'ceph-rpm-under-test',
+                Raw(';'),
+                'sudo', 'zypper', '-n', '--no-gpg-checks', 'refresh'
             ])
         else:
             self.remote.run(args=['sudo', 'yum', '-y', 'install', url])
index 8ec87c11690caf7982f06fe8061cfc5b228ffa73..6023cc075dd20363d7b6f0480d5450c9d52f1af2 100644 (file)
@@ -26,7 +26,7 @@ def _remove(ctx, config, remote, rpm):
 
     if dist_release in ['opensuse', 'sle']:
         pkg_mng_cmd = 'zypper'
-        pkg_mng_opts = '-n'
+        pkg_mng_opts = '-n --no-gpg-checks'
         pkg_mng_subcommand_opts = '--capability'
     else:
         pkg_mng_cmd = 'yum'
@@ -132,7 +132,7 @@ def _update_package_list_and_install(ctx, remote, rpm, config):
 
     if dist_release in ['opensuse', 'sle']:
         pkg_mng_cmd = 'zypper'
-        pkg_mng_opts = '-n'
+        pkg_mng_opts = '-n --no-gpg-checks'
         pkg_mng_subcommand_opts = '--capability'
     else:
         pkg_mng_cmd = 'yum'