From d049755f8242e3dd51a42c5cde613b7e27b6abad Mon Sep 17 00:00:00 2001 From: Giulio Coa Date: Sat, 6 Aug 2022 05:33:14 +0200 Subject: [PATCH] fix(installer): fix code style Fix a code style bug --- auto_install/install.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/auto_install/install.sh b/auto_install/install.sh index e2a66da..4e74ebb 100755 --- a/auto_install/install.sh +++ b/auto_install/install.sh @@ -661,30 +661,37 @@ preconfigurePackages() { # to install wireguard-tools. [[ "${WIREGUARD_BUILTIN}" -eq 1 && -n "${AVAILABLE_WIREGUARD}" ]] \ || + # If the package is not available, on Debian and Raspbian we can # add it via Bullseye repository. [[ "${WIREGUARD_BUILTIN}" -eq 1 && ("${PLAT}" == 'Debian' || "${PLAT}" == 'Raspbian') ]] \ || + # If the module is not builtin, on Raspbian we know the headers # package: raspberrypi-kernel-headers [[ "${PLAT}" == 'Raspbian' ]] \ || + # On Alpine, the kernel must be linux-lts or linux-virt if we want to # load the kernel module [[ "${PLAT}" == 'Alpine' && ! -f /.dockerenv && "$(uname -mrs)" =~ ^Linux\ +[0-9\.\-]+\-((lts)|(virt))\ +.*$ ]] \ || + # On Alpine Docker Container, the responsibility to have a WireGuard # module on the host system is at user side [[ "${PLAT}" == 'Alpine' && -f /.dockerenv ]] \ || + # On Debian (and Ubuntu), we can only reliably assume the headers package # for amd64: linux-image-amd64 [[ "${PLAT}" == 'Debian' && "${DPKG_ARCH}" == 'amd64' ]] \ || + # On Ubuntu, additionally the WireGuard package needs to be available, # since we didn't test mixing Ubuntu repositories. [[ "${PLAT}" == 'Ubuntu' && "${DPKG_ARCH}" == 'amd64' && -n "${AVAILABLE_WIREGUARD}" ]] \ || + # Ubuntu focal has wireguard support [[ "${PLAT}" == 'Ubuntu' && "${DPKG_ARCH}" == 'arm64' && "${OSCN}" == 'focal' && -n "${AVAILABLE_WIREGUARD}" ]] then