From 1dabe873fcae79c7e92b42616f05479e5aa20a4d Mon Sep 17 00:00:00 2001 From: KAAN DIKEC <21171681+dikeckaan@users.noreply.github.com> Date: Wed, 17 May 2023 12:20:11 +0300 Subject: [PATCH 1/3] Update wireguard-install.sh Changed ipv4 and ipv6 dedection methot (To get public ip) --- wireguard-install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wireguard-install.sh b/wireguard-install.sh index 2f95ecb..618f88c 100644 --- a/wireguard-install.sh +++ b/wireguard-install.sh @@ -110,10 +110,10 @@ function installQuestions() { echo "" # Detect public IPv4 or IPv6 address and pre-fill for the user - SERVER_PUB_IP=$(ip -4 addr | sed -ne 's|^.* inet \([^/]*\)/.* scope global.*$|\1|p' | awk '{print $1}' | head -1) + SERVER_PUB_IP=$(curl -4 https://ifconfig.co) if [[ -z ${SERVER_PUB_IP} ]]; then # Detect public IPv6 address - SERVER_PUB_IP=$(ip -6 addr | sed -ne 's|^.* inet6 \([^/]*\)/.* scope global.*$|\1|p' | head -1) + SERVER_PUB_IP=$(curl -6 https://ifconfig.co) fi read -rp "IPv4 or IPv6 public address: " -e -i "${SERVER_PUB_IP}" SERVER_PUB_IP From 892e2bc104918930e63b53d65d82eee29b316d46 Mon Sep 17 00:00:00 2001 From: KAAN DIKEC <21171681+dikeckaan@users.noreply.github.com> Date: Thu, 25 May 2023 20:04:41 +0300 Subject: [PATCH 2/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a8fe265..7332a17 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ Supported distributions: Download and execute the script. Answer the questions asked by the script and it will take care of the rest. ```bash -curl -O https://raw.githubusercontent.com/angristan/wireguard-install/master/wireguard-install.sh +curl -O https://raw.githubusercontent.com/dikeckaan/wireguard-install/master/wireguard-install.sh chmod +x wireguard-install.sh ./wireguard-install.sh ``` From 61b7d2a08507b3041a8724f93f24493cbaaed194 Mon Sep 17 00:00:00 2001 From: KAAN DIKEC <21171681+dikeckaan@users.noreply.github.com> Date: Thu, 25 May 2023 20:07:30 +0300 Subject: [PATCH 3/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7332a17..a8fe265 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ Supported distributions: Download and execute the script. Answer the questions asked by the script and it will take care of the rest. ```bash -curl -O https://raw.githubusercontent.com/dikeckaan/wireguard-install/master/wireguard-install.sh +curl -O https://raw.githubusercontent.com/angristan/wireguard-install/master/wireguard-install.sh chmod +x wireguard-install.sh ./wireguard-install.sh ```