1
1
mirror of https://github.com/OpenVoiceOS/OpenVoiceOS synced 2024-12-18 20:03:16 +01:00
OpenVoiceOS/buildroot-external/package/wifi-connect/start-wifi-connect
j1nx 15f01f6d4a MycroftOS: Give the system some time to get the wifi up.
- export dbus for NetworkManager
- give it 15 seconds to get the wifi up before checking SSID connectivity.
2020-07-22 10:29:30 +02:00

13 lines
248 B
Bash
Executable File

#!/usr/bin/env bash
export DBUS_SYSTEM_BUS_ADDRESS=unix:path=/run/dbus/system_bus_socket
sleep 15
iwgetid -r
if [ $? -eq 0 ]; then
printf 'Skipping WiFi Connect\n'
else
printf 'Starting WiFi Connect\n'
/usr/local/sbin/wifi-connect
fi