wireguard-tools/contrib/android/install.sh
Jason A. Donenfeld 91fb17a014 android: add port of wg-quick
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2017-07-24 23:19:38 +02:00

15 lines
440 B
Bash
Executable file

#!/bin/sh
mount -o rw,remount /system
cp -v ./addonsd.sh /system/addon.d/40-wireguard.sh
if [ -f ./wg ]; then
cp -v ./wg /system/xbin/wg
else
echo "Warning: this directory does not contain wg. You may have forgotten to compile it yourself?" >&2
fi
cp -v ./wg-quick.bash /system/xbin/wg-quick
chmod 755 /system/xbin/wg /system/xbin/wg-quick /system/addon.d/40-wireguard.sh
mkdir -pvm 700 /data/misc/wireguard
mount -o ro,remount /system