Force ping to use a specific address.

This helps when there are multiple networks available on the device running
tuya-convert, as it will force the pings to go via the interface that the
device will convert to, not the default interface.
This commit is contained in:
Matthew Schinckel
2021-07-27 11:23:05 +01:00
parent 61ba060b85
commit eaaa1e71cc

View File

@@ -75,7 +75,7 @@ while true; do
# The intermediate firmware will request 10.42.42.42
# Do NOT change this address!!!
# It will NOT make it install and will break this script
while ! ping -c 1 -W 1 -n 10.42.42.42 &> /dev/null; do
while ! ping -c 1 -W 1 -n 10.42.42.42 -S 10.42.42.1 &> /dev/null; do
printf .
if (( --i == 0 )); then
echo