Commit Graph

10 Commits

Author SHA1 Message Date
Andrew J. Hesford 9d7eba40d1 Improve version handling in the repository and ZBM images
- Track installed version in ${zfsbootmenu_module_root}/zbm-release

- Install zbm-release as /etc/zbm-release in ZFSBootMenu images

- Add releng/version.sh to manage repository versioning

- Mark post-release development versions as part of release tagging

- Improve version handling in ZFSBootMenu build containers:

  * zbm-builder.sh: allow temporary, writable overlays of /zbm

  * releng/docker/build-init.sh: update ZBM version when possible

  * releng/docker/image-build.sh: install git in standard images
2023-11-26 15:03:46 -05:00
Zach Dykstra 3f3e831e80
zfsbootmenu: make zbm.autosize a system hook
Vendor a subset of Terminus console fonts and add a basic installation
routine to Dracut/mkinitcpio modules.
2023-09-16 19:41:32 -05:00
Andrew J. Hesford 640af57ad6 Refactor user runtime hooks installation and processing
- Add new hook points: load-key.d and boot-sel.d

- All hooks are installed in hook-point-specific subdirectories of
  /libexec/hooks instead of in the top-level /libexec

- User hooks are recognized in level-specific subdirectories of a
  zfsbootmenu_hook_root defined for dracut or mkinitcpio

- Deprecate zfsbootmenu_{early_setup,setup,teardown} variables

- Take advantage of zfsbootmenu_hook_root to simplify hooks in container
  builds via zbm-builder.sh

- Simplify zbm.hookdir overrides

Closes: #477.
2023-09-12 21:15:04 -04:00
Zach Dykstra ff5956298a zfsbootmenu: refactor installation, support system and user runtime hooks
- All core components, docs and runtime hooks are handled by a common
  install_helper that is aware of both dracut and mkinitcpio methods

- Installation now adds "system" runtime hooks in addition to those
  configured by the user; user hooks with names that conflict with
  system hooks will "mask" the system version

- The hooks `10-console-init.sh` and `xhci-teardown.sh` have been
  elevated to "system" status and are always installed in ZBM images

- The `zfsbootmenu/hook` path has been renamed to `zfsbootmenu/pre-init`
  to avoid confusion with the new `zfsbootmenu/hooks` directory of
  system runtime hooks, and the dracut-only `hook` scripts have been
  moved to the dracut module

- A new `zbm.skip_hooks` command-line argument allows a comma-separated
  list of hooks to skip (matched on basename only) to provide an easy
  mechanism for skipping default hooks without `zbm.hookroot`

- Create the `zfsbootmenu-run-hooks` libexec helper, allowing easy
  addition of future hook points.

Co-authored-by: Zach Dykstra <dykstra.zachary@gmail.org>
Co-authored-by: Andrew J. Hesford <ajh@sideband.org>
2023-09-12 10:32:31 -04:00
Andrew J. Hesford 56cbbe814d dracut, initcpio: make libgcc_s search universal
Closes: #427.
2023-07-17 15:34:05 -04:00
Zach Dykstra 7f929f1ad9 Add compatibility.d definitions to image 2022-12-15 09:45:48 -06:00
Andrew J. Hesford 235eb17d1a Stop installing zpool.cache
None of the `zpool import` instances actually use the cache file, so
there is no value in including it in the initramfs.
2022-11-28 20:27:56 -05:00
Andrew J. Hesford 65167e6982 Define all ZBM requirements in install-helpers.sh
Required and optional kernel modules, binaries and udev rules are all
provided as arrays in install-helpers.sh to provide a single point for
altering requirements.
2022-01-27 12:56:11 -05:00
Zach Dykstra 91b4b3bc4d De-prioritize Dracut as the primary generator
All core ZFSBootMenu libraries / hooks / binaries have been moved to a
generic 'zfsbootmenu' directory intended to be installed in /usr/share.
The dracut-specific module-setup.sh script has been moved to a 'dracut'
directory and it, along with the 'initcpio' hook scripts, have been
adapted to use common tooling in 'zfsbootmenu/install-helpers.sh'. Both
of these refer to the core components in '/usr/share/zfsbootmenu' when
creating a new image. The zbm-kcl utilit looks there by default.

The testing tools are now capable of producing images with mkinitcpio.

Co-authored-by: Zach Dykstra <dykstra.zachary@gmail.com>
Co-authored-by: Andrew J. Hesford <ajh@sideband.org>
2022-01-27 12:56:11 -05:00
Andrew J. Hesford 1fe8c4c48c Add support for mkinitcpio
A mkinitcpio hook (and its install script) under the `initcpio`
directory now allows a ZBM image to be created without dracut. This
provides a couple of benefits over the dracut dependency:

- As dracut gets further centered on systemd, ZBM needs an alternative

- The mkinitcpio process is greatly simplified and more configurable

- Arch users can build images with their native generator
2022-01-27 12:56:11 -05:00