system-config/setup.sh
Mathieu Strypsteen 5e947beb2a
All checks were successful
ShellCheck / shellcheck (push) Successful in 17s
Update kernel lockdown
2025-01-21 11:41:56 +01:00

34 lines
726 B
Bash
Executable file

#!/bin/bash
set -euo pipefail
cd "$(dirname "$0")"
if [ "$USER" != root ]; then
echo "Needs to be run as root" >&2
exit 1
fi
if [ -f /etc/qubes-release ]; then
bash setup-qubes.sh
exit
fi
if [ ! -f /etc/fedora-release ]; then
exit
fi
bash setup-common.sh
if [ -f /usr/share/qubes/marker-vm ]; then
bash setup-qubes-fedora.sh
elif [ -d /usr/lib/coreos ]; then
if [ "$1" = vps ]; then
bash setup-vps.sh
elif [ "$1" = home ]; then
bash setup-home.sh
elif [ "$1" = sandbox ]; then
bash setup-sandbox.sh
elif [ "$1" = infra ]; then
bash setup-infra.sh
fi
elif [ -d /ostree ]; then
if [ "$1" = laptop ]; then
bash setup-laptop.sh
elif [ "$1" = gpu ]; then
bash setup-gpu.sh
fi
fi