forked from Mirror/pmbootstrap
chroot: apk: pass in both repos (MR 2377)
Pass in --repository for all channels not just the default. Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
This commit is contained in:
parent
d8e5037336
commit
f07ceca9c6
1 changed files with 6 additions and 8 deletions
|
@ -201,10 +201,6 @@ def install_run_apk(to_add: list[str], to_add_local: list[Path], to_del: list[st
|
||||||
commands += [["del"] + to_del]
|
commands += [["del"] + to_del]
|
||||||
|
|
||||||
channel = pmb.config.pmaports.read_config()["channel"]
|
channel = pmb.config.pmaports.read_config()["channel"]
|
||||||
# FIXME: use /mnt/pmb… until MR 2351 is reverted (pmb#2388)
|
|
||||||
# user_repo = work / "packages" / channel
|
|
||||||
user_repo = os.path.join("/mnt/pmbootstrap/packages/", channel)
|
|
||||||
|
|
||||||
# There are still some edgecases where we manage to get here while the chroot is not
|
# There are still some edgecases where we manage to get here while the chroot is not
|
||||||
# initialized. To not break the build, we initialize it here but print a big warning
|
# initialized. To not break the build, we initialize it here but print a big warning
|
||||||
# and a stack trace so hopefully folks report it.
|
# and a stack trace so hopefully folks report it.
|
||||||
|
@ -214,14 +210,16 @@ def install_run_apk(to_add: list[str], to_add_local: list[Path], to_del: list[st
|
||||||
traceback.print_stack(file=logging.logfd)
|
traceback.print_stack(file=logging.logfd)
|
||||||
pmb.chroot.init(chroot)
|
pmb.chroot.init(chroot)
|
||||||
|
|
||||||
|
# FIXME: use /mnt/pmb… until MR 2351 is reverted (pmb#2388)
|
||||||
|
user_repo = []
|
||||||
|
for channel in pmb.config.pmaports.all_channels():
|
||||||
|
user_repo += ["--repository", Path("/mnt/pmbootstrap/packages") / channel]
|
||||||
|
|
||||||
for i, command in enumerate(commands):
|
for i, command in enumerate(commands):
|
||||||
# --no-interactive is a parameter to `add`, so it must be appended or apk
|
# --no-interactive is a parameter to `add`, so it must be appended or apk
|
||||||
# gets confused
|
# gets confused
|
||||||
command += ["--no-interactive"]
|
command += ["--no-interactive"]
|
||||||
command = [
|
command = user_repo + command
|
||||||
"--repository",
|
|
||||||
user_repo,
|
|
||||||
] + command
|
|
||||||
|
|
||||||
# Ignore missing repos before initial build (bpo#137)
|
# Ignore missing repos before initial build (bpo#137)
|
||||||
if os.getenv("PMB_APK_FORCE_MISSING_REPOSITORIES") == "1":
|
if os.getenv("PMB_APK_FORCE_MISSING_REPOSITORIES") == "1":
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue