stages/rpm: allow check_gpg to be omitted
This brings it in line with the JSON schema. Also fix a bug where the wrong root was used for checking the signatures. Signed-off-by: Tom Gundersen <teg@jklm.no>
This commit is contained in:
parent
b0bf9c9392
commit
72e1e7217b
1 changed files with 7 additions and 6 deletions
|
|
@ -101,12 +101,13 @@ def main(tree, sources, options):
|
||||||
osbuild.sources.get("org.osbuild.files", checksums)
|
osbuild.sources.get("org.osbuild.files", checksums)
|
||||||
|
|
||||||
for pkg in packages:
|
for pkg in packages:
|
||||||
if pkg["check_gpg"]:
|
if pkg.get("check_gpg"):
|
||||||
subprocess.run(
|
subprocess.run([
|
||||||
["rpmkeys", "--checksig", pkg["checksum"]],
|
"rpmkeys",
|
||||||
cwd=f"{sources}/org.osbuild.files",
|
"--root", tree,
|
||||||
stdout=subprocess.DEVNULL,
|
"--checksig",
|
||||||
check=True)
|
pkg["checksum"]
|
||||||
|
], cwd=f"{sources}/org.osbuild.files", stdout=subprocess.DEVNULL, check=True)
|
||||||
|
|
||||||
script = f"""
|
script = f"""
|
||||||
set -e
|
set -e
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue