Skip to content

Commit

Permalink
fix(wifi): create and set ui directory
Browse files Browse the repository at this point in the history
  • Loading branch information
luandro committed Jun 18, 2024
1 parent 58e18a3 commit 5b1696d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions services/wifi-connect/start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ sleep 30
# 4. Is there an active WiFi connection?
# iwgetid -r
SSID="${SSID:=Earth_Defenders_Toolkit}"
mkdir -p /usr/src/app/frontend
# TODO: change url to $HOSTNAME.local variable
cat <<'END_HTML' >/usr/src/app/ui/index.html
cat <<'END_HTML' >/usr/src/app/frontend/index.html
<!DOCTYPE HTML>
<html lang="en-US">
<head>
Expand All @@ -46,7 +47,7 @@ if [ $? -eq 0 ]; then
printf 'Skipping WiFi Connect\n'
else
printf 'Starting Earth Defenders Toolkit Hotspot and Captive-Portal\n'
./wifi-connect --portal-ssid "$SSID"
./wifi-connect --portal-ssid "$SSID" --ui-directory "/usr/src/app/frontend"
fi

# Start your application here.
Expand Down

0 comments on commit 5b1696d

Please sign in to comment.