stages/dnf: make install_weak_deps optional
Default to True, which is what dnf defaults to, but allow it to be overridden in the pipeline. Whether this option should be used should be a distro policy, but for now we just want it to get images compatible with the official fedora ones. Signed-off-by: Tom Gundersen <teg@jklm.no>
This commit is contained in:
parent
b348d858b8
commit
9af32f1aae
1 changed files with 2 additions and 1 deletions
|
|
@ -10,6 +10,7 @@ def main(tree, options):
|
|||
packages = options["packages"]
|
||||
releasever = options["releasever"]
|
||||
operation = options.get("operation", "install")
|
||||
weak_deps = options.get("install_weak_deps", True)
|
||||
|
||||
with open("/tmp/dnf.conf", "w") as conf:
|
||||
for repoid, repo in repos.items():
|
||||
|
|
@ -45,7 +46,7 @@ def main(tree, options):
|
|||
"dnf", "-yv",
|
||||
"--installroot", tree,
|
||||
"--setopt", "reposdir=",
|
||||
"--setopt", "install_weak_deps=False",
|
||||
"--setopt", f"install_weak_deps={weak_deps}",
|
||||
"--releasever", releasever,
|
||||
"--disableplugin=generate_completion_cache", # supress error that completion db can't be opened
|
||||
"--config", "/tmp/dnf.conf",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue