Changed healthcheck to only ping 1.1.1.1 to check connectivity

This is because your VPN public IP might not be the VPN server entrance IP address, resulting in the container being unhealthy most of the time.
This commit is contained in:
Quentin McGaw
2019-01-15 14:40:28 +01:00
parent 370098f5ca
commit a3bfa2d77a
4 changed files with 18 additions and 12 deletions

9
healthcheck.sh Normal file
View File

@@ -0,0 +1,9 @@
#!/bin/sh
ping -W 1 -w 1 -q -s 8 1.1.1.1 &> /dev/null
status=$?
if [ $status = 0 ]; then
exit 0
fi
printf "Pinging 1.1.1.1 resulted in error status code $status"
exit 1