mirror of
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap.git
synced 2025-07-12 19:09:56 +03:00
chroot: make sure that we bootstrap the chroot /usr-merged
This is needed because the /usr-merge is not compulsory in Alpine, but only new installs, and people that volunteer to migrate get it. Depends https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6389 More details: https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/85504#note_521927
This commit is contained in:
parent
c9674c4455
commit
f8d7d8ea2e
1 changed files with 4 additions and 2 deletions
|
@ -155,10 +155,12 @@ def init(chroot: Chroot, usr_merge: UsrMerge = UsrMerge.AUTO) -> None:
|
|||
# Install minimal amount of things to get a functional chroot.
|
||||
# We don't use alpine-base since it depends on openrc, and neither
|
||||
# postmarketos-base, since that's quite big (e.g: contains an init system)
|
||||
# The bootstrapping is done in 2 steps due to the /usr merge
|
||||
pmb.helpers.repo.update(arch)
|
||||
pkgs = ["alpine-baselayout", "apk-tools", "busybox", "musl-utils"]
|
||||
cmd: list[PathString] = ["--initdb"]
|
||||
pmb.helpers.apk.run([*cmd, "add", *pkgs], chroot)
|
||||
pmb.helpers.apk.run([*cmd, "add", "alpine-baselayout-core"], chroot)
|
||||
pkgs = ["alpine-baselayout", "apk-tools", "busybox", "musl-utils"]
|
||||
pmb.helpers.apk.run(["add", *pkgs], chroot)
|
||||
|
||||
# Merge /usr
|
||||
if usr_merge is UsrMerge.AUTO and pmb.config.is_systemd_selected(config):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue