mirror of
https://github.com/angristan/wireguard-install.git
synced 2024-11-24 05:56:02 +03:00
Make sure kernel headers are installed
Fix #24. On Fedora/CentOS, kernel-headers is a dependency
This commit is contained in:
parent
1bfeccf9e7
commit
70ed237ffc
@ -84,11 +84,13 @@ fi
|
|||||||
if [[ "$OS" = 'ubuntu' ]]; then
|
if [[ "$OS" = 'ubuntu' ]]; then
|
||||||
add-apt-repository ppa:wireguard/wireguard
|
add-apt-repository ppa:wireguard/wireguard
|
||||||
apt-get update
|
apt-get update
|
||||||
|
apt-get install linux-headers-$(uname -r)
|
||||||
apt-get install wireguard
|
apt-get install wireguard
|
||||||
elif [[ "$OS" = 'debian' ]]; then
|
elif [[ "$OS" = 'debian' ]]; then
|
||||||
echo "deb http://deb.debian.org/debian/ unstable main" > /etc/apt/sources.list.d/unstable.list
|
echo "deb http://deb.debian.org/debian/ unstable main" > /etc/apt/sources.list.d/unstable.list
|
||||||
printf 'Package: *\nPin: release a=unstable\nPin-Priority: 90\n' > /etc/apt/preferences.d/limit-unstable
|
printf 'Package: *\nPin: release a=unstable\nPin-Priority: 90\n' > /etc/apt/preferences.d/limit-unstable
|
||||||
apt update
|
apt update
|
||||||
|
apt-get install linux-headers-$(uname -r)
|
||||||
apt install wireguard
|
apt install wireguard
|
||||||
elif [[ "$OS" = 'fedora' ]]; then
|
elif [[ "$OS" = 'fedora' ]]; then
|
||||||
dnf copr enable jdoss/wireguard
|
dnf copr enable jdoss/wireguard
|
||||||
@ -98,6 +100,7 @@ elif [[ "$OS" = 'centos' ]]; then
|
|||||||
yum install epel-release
|
yum install epel-release
|
||||||
yum install wireguard-dkms wireguard-tools
|
yum install wireguard-dkms wireguard-tools
|
||||||
elif [[ "$OS" = 'arch' ]]; then
|
elif [[ "$OS" = 'arch' ]]; then
|
||||||
|
pacman -S linux-headers
|
||||||
pacman -S wireguard-tools
|
pacman -S wireguard-tools
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user