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

Add DNS resolution checks to start and healthcheck scripts #1608

Closed
clement-z opened this issue Dec 14, 2020 · 0 comments
Closed

Add DNS resolution checks to start and healthcheck scripts #1608

clement-z opened this issue Dec 14, 2020 · 0 comments

Comments

@clement-z
Copy link
Contributor

Is your feature request related to a problem? Please describe.

DNS problems are quite frequent and easy to resolve. However, it is not always clear to the user that it is what fails. I think we should add a simple DNS resolution check at the start of the script and possibly in the healthcheck script to verify DNS is set up properly in the container. If it is not working, then we can show it clearly in the logs and exit.

Describe the solution you'd like

Add something along the lines of:

echo "Checking dns resolution is working"
nslookup ${HEALTH_CHECK_HOST:-google.com} >/dev/null 2>&1
dns_ret_code=$?
# [...] 

to openvpn/start.sh and scripts/healthcheck.sh.

pkishino added a commit that referenced this issue Jan 19, 2021
* Add dns resolution test to healthcheck script

* Add dns resolution test to start script

Co-authored-by: Patrick Kishino <[email protected]>
steveneighbour pushed a commit to steveneighbour/openvpn that referenced this issue Apr 17, 2021
* Add dns resolution test to healthcheck script

* Add dns resolution test to start script

Co-authored-by: Patrick Kishino <[email protected]>
steveneighbour pushed a commit to steveneighbour/openvpn that referenced this issue Apr 17, 2021
* Brush up proxy and rss plugin images, build for multiarch support haugene#1483

* Escape special characters in rss-plugin input variables haugene#1565

* Increase healthcheck ping timeout (haugene#1627)

* Add DNS resolution checks (fix haugene#1608) (haugene#1617)

* Add dns resolution test to healthcheck script

* Add dns resolution test to start script

Co-authored-by: Patrick Kishino <[email protected]>

* Fix PIA infinite redirect on config download (see haugene#1619) (haugene#1620)

PIA download link was redirecting and setting a cookie, but those are
disabled by default unless `--cookie` or `--cookie-jar` are given. Since
the cookie was not set, the redirection was attempted again until we
reached the maximum redirection limit.

The `--cookie /dev/null` specifies an empty input cookie, which has the
effect to enable curl's handling of cookies.

Co-authored-by: Kristian Haugene <[email protected]>
Co-authored-by: clement-z <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant