HomeFreeBSD

stand/lua: per-product conf if requested via product_vars

Description

stand/lua: per-product conf if requested via product_vars

If product_vars is set, it must be a space separated list of environment
variable names to walk through to guess the product. Each time a product can be
guessed (i.e., the corresponding variable is defined), prepend
/boot/loader.conf.d/PRODUCT/ to loader_conf_dirs.

It can be typically used as follow:

smbios.system.planar.maker="PLANAR_MAKER"
smbios.system.planar.product="PLANAR_PRODUCT"
smbios.system.product="PRODUCT"
uboot.m_product="M_PRODUCT"
product_vars="smbios.system.planar.maker smbios.system.planar.product smbios.system.product uboot.m_product"

to read files found in the following directories, in that order:

/boot/loader.conf.d/PLANAR_MAKER
/boot/loader.conf.d/PLANAR_PRODUCT
/boot/loader.conf.d/PRODUCT
/boot/loader.conf.d/M_PRODUCT

Reviewed by: imp, kevans
Pull Request: https://github.com/freebsd/freebsd-src/pull/759

Details

Provenance
stephane.rochoy_stormshield.euAuthored on May 4 2023, 7:23 AM
impCommitted on Feb 2 2024, 7:04 PM
Parents
rG994865caf250: Revert "stand/lua: per-product conf if requested via product_vars"
Branches
Unknown
Tags
Unknown