2024-08-16 13:14:54 -03:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Perform the health check by pinging the xbnet interface
|
|
|
|
# - If the xbnet0 interface is successfully created, we should be able to ping the assigned IP
|
2024-08-26 16:57:24 -03:00
|
|
|
ping -c 1 "$XBEE_NET_SRC_IP" > /dev/null 2>&1
|
2024-08-16 13:14:54 -03:00
|
|
|
|
|
|
|
# Return the appropriate status based on ping success
|
|
|
|
if [ $? -eq 0 ]; then
|
|
|
|
exit 0
|
|
|
|
else
|
|
|
|
exit 1
|
|
|
|
fi
|