Reimplement initial fail

This commit is contained in:
Joshua Boniface 2023-09-01 15:41:54 -04:00
parent 02a5507523
commit cb3cb4a706
1 changed files with 5 additions and 0 deletions

View File

@ -7,6 +7,11 @@
# using a standard Debian intaller ISO. The end system is suitable # using a standard Debian intaller ISO. The end system is suitable
# for immediate bootstrapping with the PVC Ansible roles. # for immediate bootstrapping with the PVC Ansible roles.
fail() {
echo "$@"
exit 1
}
which debootstrap &>/dev/null || fail "This script requires debootstrap." which debootstrap &>/dev/null || fail "This script requires debootstrap."
which mksquashfs &>/dev/null || fail "This script requires squashfs." which mksquashfs &>/dev/null || fail "This script requires squashfs."
which xorriso &>/dev/null || fail "This script requires xorriso." which xorriso &>/dev/null || fail "This script requires xorriso."