Skip to content

Commit

Permalink
minor fixes in the installation wizard
Browse files Browse the repository at this point in the history
  • Loading branch information
mosajjal committed May 4, 2023
1 parent f698e02 commit b20546a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions install.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

# check distro and root
# check distro and root
if [ -f /etc/debian_version ]; then
echo "Debian/Ubuntu detected"
if [ "$(id -u)" != "0" ]; then
Expand All @@ -25,7 +25,7 @@ if [ ! -d /run/systemd/system ]; then
exit 1
fi

# prompt before removing stub resolver
# prompt before removing stub resolver
echo "This script will remove the stub resolver from /etc/resolv.conf"
echo "and replace it with 9.9.9.9"
echo "Press Ctrl-C to abort or Enter to continue"
Expand All @@ -38,7 +38,7 @@ if ! command -v sed &> /dev/null; then
fi

# remove stub resolver
sed -i 's/#DNS=/DNS=9.9.9.9/; s/#DNSStubListener=yes/DNSStubListener=no/' /etc/systemd/resolved.conf
sed -i 's/#DNS=/DNS=9.9.9.9/; s/#DNSStubListener=yes/DNSStubListener=no/' /etc/systemd/resolved.conf
systemctl restart systemd-resolved

# check if stub resolver is removed by checking netstat for port 53 udp. try both ss and netstat
Expand Down Expand Up @@ -112,7 +112,7 @@ if [ "$dnsOverTLS" = "y" ] || [ "$dnsOverQUIC" = "y" ]; then
if [ -z "$certPath" ] || [ -z "$keyPath" ]; then
echo "WARNING: Using self-signed certificates"
else
execCommand="$execCommand --certPath $certPath --keyPath $keyPath"
execCommand="$execCommand --tlsCert $certPath --tlsKey $keyPath"
fi
fi

Expand Down Expand Up @@ -155,4 +155,4 @@ echo "if journal shows empty, you might need to reboot the server, sniproxy is s

# we're done
echo "Done"
exit 0
exit 0

0 comments on commit b20546a

Please sign in to comment.