Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Menu Point 16 will exit script #421

Open
Gill-Bates opened this issue Dec 31, 2023 · 1 comment
Open

Menu Point 16 will exit script #421

Gill-Bates opened this issue Dec 31, 2023 · 1 comment

Comments

@Gill-Bates
Copy link

Running the script and selecting Point 16 will exit the script.

Bug or Feature?

@Prajwal-Koirala
Copy link
Member

Prajwal-Koirala commented Dec 31, 2023

https://github.com/complexorganizations/wireguard-manager

Please join the discord server i beg you.

16)
# Check if the `unbound` command is available on the system by checking if it is executable
if [ -x "$(command -v unbound)" ]; then
# Check if the output of `unbound-checkconf` run on `UNBOUND_CONFIG` contains "no errors"
if [[ "$(unbound-checkconf ${UNBOUND_CONFIG})" != *"no errors"* ]]; then
# If "no errors" was not found in output of previous command, print an error message
echo "Error: We found an error on your unbound config file located at ${UNBOUND_CONFIG}"
exit
fi
# Check if output of `unbound-host` run on `UNBOUND_CONFIG` with arguments `-C`, `-v`, and `cloudflare.com` contains "secure"
if [[ "$(unbound-host -C ${UNBOUND_CONFIG} -v cloudflare.com)" != *"secure"* ]]; then
# If "secure" was not found in output of previous command, print an error message
echo "Error: We found an error on your unbound DNS-SEC config file loacted at ${UNBOUND_CONFIG}"
exit
fi
echo "Your unbound config file located at ${UNBOUND_CONFIG} is valid."
fi
;;
esac
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants