# Configuration for the contextual process job.
#
# Contextual processes are based on **global** configuration values.
# When a given global value (string) equals a given value, then
# the associated command is executed.
#
# The special top-level keys *dontChroot* and *timeout* have
# meaning just like in shellprocess.conf. They are excluded from
# the comparison with global variables.
#
# Configuration consists of keys for global variable names (except
# *dontChroot* and *timeout*), and the sub-keys are strings to compare
# to the variable's value. If the variable has that particular value, the
# corresponding value (script) is executed.
#
# You can check for an empty value with "".
#
# As a special case, the value-check "*" matches any value, but **only**
# if no other value-check matches. Use it as an *else* form for value-
# checks. Take care to put the asterisk in quotes. The value-check "*"
# **also** matches a literal asterisk as value; a confusing corner case
# is checking for an asterisk **and** having a wildcard match with
# different commands. This is currently not possible.
#
# Global configuration variables are not checked in a deterministic
# order, so do not rely on commands from one variable-check to
# always happen before (or after) checks on another
# variable. Similarly, the value-equality checks are not
# done in a deterministic order, but all of the value-checks
# for a given variable happen together. As a special case, the
# value-check for "*" (the *else* case) happens after all of the
# other value-checks, and only matches if none of the others do.
#
# The values after a value sub-keys are the same kinds of values
# as can be given to the *script* key in the shellprocess module.
# See shellprocess.conf for documentation on valid values.
---
dontChroot: false
firmwareType:
    efi:
        -   "-pkg remove efi-firmware"
        -   command: "-mkinitramfsrd -abgn"
            timeout: 120  # This is slow
    bios:   "-pkg remove bios-firmware"
    "":     "/bin/false no-firmware-type-set"
    "*":    "/bin/false some-other-firmware-value"
