Skip to content

pmbootstrap install --no-local-pkgs: new option

Oliver Smith requested to merge no-local-pkgs into master

Two patches:

pmbootstrap install: make building pkgs optional

Add a question at the end of "pmbootstrap init", to ask if the user
wants to build outdated packages during "pmbootstrap install". Store the
result in the new pmbootstrap.cfg key "install_build_pkgs". I've put it at
the end, because it is a rather complicated question compared to the rest.

This is useful to speed up the installation for casual users who can now
avoid compiling packages. But also for the official images where we only
want to ship the official binary packages and not build anything
on-the-fly.
pmbootstrap install --no-local-pkgs: new option

Don't install locally compiled packages and package signing keys. This
will be used for the official images generated with pmbootstrap.

Test plan for the "pmbootstrap init" option:

$ pmbootstrap init  # find the new question at the end
$ pmbootstrap pkgrel_bump postmarketos-base
$ yes | pmbootstrap install  # should not build packages if question was answered with 'n'

Test plan for --no-local-pkgs:

$ pmbootstrap -y zap -p
$ pmbootstrap pkgrel_bump postmarketos-base
$ pmbootstrap config device qemu-amd64
$ pmbootstrap build postmarketos-base
$ yes | pmbootstrap install --no-local-pkgs  # should complain that local packages exist
$ pmbootstrap -y zap -p
$ yes | pmbootstrap install --no-local-pkgs  # should pass, without building any packages
$ pmbootstrap qemu &
$ ssh -p 2222 user@localhost
# ls -1 /etc/apk/keys  # should only have official keys, no local key
# apk info -vv | grep hello-world  # should have outdated hello-world 1-r5

Closes #1931 (closed)

Merge request reports