Fixed logic determining OS | Added option to choose between Host/VM kernel

This commit is contained in:
optout 2024-03-05 05:33:27 +00:00
parent 030ce84b1f
commit d801df98a9
No known key found for this signature in database
GPG Key ID: 13BA4BD4C14170C0
1 changed files with 1 additions and 2 deletions

View File

@ -60,19 +60,18 @@ if [[ ! -d /usr/src/linux-hardened-"$KVER" ]]; then
tar -xf "$KVER".tar.gz -C /usr/src/
fi
# Move to staging directory
cd /usr/src/linux-hardened-"$KVER"
# Pull down plague kconfig
read -rp 'Are you compiling this kernel for a physical machine (host) or virtual machine (VM)? [host/vm]: ' response
if [[ "${response,,}" = "vm" ]]
then
# Perform task(s) specifically for VM environments
echo "Compiling a VM kernel"
wget https://0xacab.org/optout/plague-kernel/-/raw/main/virt_hardened.config -O .config
## virt_hardened.config is still a WIP
elif [[ "${response,,}" = "host" ]]
then
# Perform task(s) specifically for Host environments
echo "Compiling a host kernel"
wget https://0xacab.org/optout/plague-kernel/-/raw/main/host_hardened.config -O .config
else