HEX
Server: nginx/1.16.1
System: Linux ecs-04358622 4.19.90-2107.6.0.0100.oe1.bclinux.x86_64 #1 SMP Wed Dec 1 19:59:44 CST 2021 x86_64
User: nginx (994)
PHP: 8.0.0
Disabled: NONE
Upload Files
File: //usr/lib/dracut/modules.d/90stratis/module-setup.sh
#!/bin/bash

# called by dracut
check() {
    require_binaries stratisd-init thin_check thin_repair mkfs.xfs xfs_admin xfs_growfs || return 1
    return 255
}

# called by dracut
depends() {
    echo dm
    return 0
}

# called by dracut
installkernel() {
    instmods xfs
}

# called by dracut
install() {

    inst_multiple stratisd-init thin_check thin_repair mkfs.xfs xfs_admin xfs_growfs

    if dracut_module_included "systemd"; then
        inst_simple "${moddir}/stratisd-init.service" "${systemdsystemunitdir}/stratisd-init.service"
        systemctl -q --root "$initdir" enable stratisd-init.service
    else
        inst_hook pre-mount 25 "$moddir/stratisd-start.sh"
        inst_hook cleanup 25 "$moddir/stratisd-stop.sh"
    fi
}