Skip to content

Commit

Permalink
add alpine container support
Browse files Browse the repository at this point in the history
  • Loading branch information
rothdennis authored and coolapso committed Jul 19, 2023
1 parent ef6b0e8 commit 4446ea0
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions auto_install/install.sh
Expand Up @@ -43,7 +43,7 @@ BASE_DEPS+=(bsdmainutils bash-completion)

BASE_DEPS_ALPINE=(git grep bind-tools newt net-tools bash-completion coreutils)
BASE_DEPS_ALPINE+=(openssl util-linux openrc iptables ip6tables coreutils sed)
BASE_DEPS_ALPINE+=(perl)
BASE_DEPS_ALPINE+=(perl libqrencode-tools)

# Dependencies that where actually installed by the script. For example if the
# script requires grep and dnsutils but dnsutils is already installed, we save
Expand Down Expand Up @@ -665,17 +665,19 @@ preconfigurePackages() {
# if we want to load the kernel module
# case 5: On Alpine Docker Container, the responsibility to have
# a WireGuard module on the host system is at user side
# case 6: On Debian (and Ubuntu), we can only reliably assume the
# case 6: On Alpine container, wireguard-tools is available
# case 7: On Debian (and Ubuntu), we can only reliably assume the
# headers package for amd64: linux-image-amd64
# case 7: On Ubuntu, additionally the WireGuard package needs to
# case 8: On Ubuntu, additionally the WireGuard package needs to
# be available, since we didn't test mixing Ubuntu repositories.
# case 8: Ubuntu focal has wireguard support
# case 9: Ubuntu focal has wireguard support

if [[ "${WIREGUARD_BUILTIN}" -eq 1 && -n "${AVAILABLE_WIREGUARD}" ]] \
|| [[ "${WIREGUARD_BUILTIN}" -eq 1 && ("${PLAT}" == 'Debian' || "${PLAT}" == 'Raspbian') ]] \
|| [[ "${PLAT}" == 'Raspbian' ]] \
|| [[ "${PLAT}" == 'Alpine' && ! -f /.dockerenv && "$(uname -mrs)" =~ ^Linux\ +[0-9\.\-]+\-((lts)|(virt))\ +.*$ ]] \
|| [[ "${PLAT}" == 'Alpine' && -f /.dockerenv ]] \
|| [[ "${PLAT}" == 'Alpine' && -n "${AVAILABLE_WIREGUARD}" ]] \
|| [[ "${PLAT}" == 'Debian' && "${DPKG_ARCH}" == 'amd64' ]] \
|| [[ "${PLAT}" == 'Ubuntu' && "${DPKG_ARCH}" == 'amd64' && -n "${AVAILABLE_WIREGUARD}" ]] \
|| [[ "${PLAT}" == 'Ubuntu' && "${DPKG_ARCH}" == 'arm64' && "${OSCN}" == 'focal' && -n "${AVAILABLE_WIREGUARD}" ]]; then
Expand Down

0 comments on commit 4446ea0

Please sign in to comment.