Created
July 8, 2021 03:24
-
-
Save fernandohs1500/291e50f5fce69eee63772a135fb3f770 to your computer and use it in GitHub Desktop.
jbi-custom-input
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ----------------------------------------------------------------------------- | |
# input for jibri-jibri-installer | |
# ----------------------------------------------------------------------------- | |
# core | |
out <<< "checking the number of cores..." | |
CORES=$(nproc --all) | |
if [[ "$CORES" -lt 4 ]]; then | |
out <<EOF | |
Aborted! Not enough cores: $CORES | |
Recommendation: It should be at least 4 cores | |
EOF | |
exit 1 | |
fi | |
# snd_aloop | |
out <<< "checking the snd-aloop support..." | |
[[ "$DISTRO" = "focal" ]] && \ | |
apt-get $APT_PROXY_OPTION -y install linux-modules-extra-$(uname -r) \ | |
-o Dpkg::Options::="--force-confdef" \ | |
-o Dpkg::Options::="--force-confold" || \ | |
true | |
[[ "$DISTRO" = "buster" ]] && \ | |
KERNEL="linux-image-$(dpkg --print-architecture)" || \ | |
KERNEL="linux-image-generic" | |
modprobe snd_aloop 2>/dev/null || true | |
if [[ -z "$(grep snd_aloop /proc/modules)" ]]; then | |
out <<EOF | |
Aborted! This kernel ($(uname -r)) does not support snd_aloop module. | |
Recommendation: Install the standard Linux kernel package and reboot with it. | |
Probably it's the "$KERNEL" package in your case. | |
EOF | |
exit 1 | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment