Skip to content

Commit

Permalink
De-duplicate the local-repo mountpoint in bootstrap
Browse files Browse the repository at this point in the history
Complements: d4c1269
Relates: #381
Relates: #357
Relates: #1414
Relates: #1286
  • Loading branch information
praiskup committed Sep 25, 2024
1 parent c5ba879 commit 7f112ff
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
11 changes: 0 additions & 11 deletions mock/py/mockbuild/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -1001,17 +1001,6 @@ def _fix_cfg(cfg):

_fix_cfg(bootstrap.config)

if not baseurl.startswith("file:///") and not baseurl.startswith("/"):
return

local_dir = baseurl.replace("file://", "", 1)
if not local_dir or not os.path.isdir(local_dir):
return

mountpoint = bootstrap.make_chroot_path(local_dir)
bootstrap.mounts.add(BindMountPoint(srcpath=local_dir,
bindpath=mountpoint))


def subscription_redhat_init(opts, uidManager):
if not opts['redhat_subscription_required']:
Expand Down
5 changes: 5 additions & 0 deletions releng/release-notes-next/buildroot-mounts-redundancy.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
De-duplicate mount points for local repositories used with `--chain` or
`--localrepo=file:///repo/on/host`. This bug existed in Mock <= 5.6, but after
fixing the [issue#1414][], it got exposed by our test suite. Related issues
include [issue#357][] ([commit#a0a2cba3][]) and [issue#381][]
([commit#16462acc][]).

0 comments on commit 7f112ff

Please sign in to comment.