diff --git a/AGENTS.md b/AGENTS.md index e652763..a7b8ed9 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -4,6 +4,8 @@ - this projects uses poetry for package management - if something should be run in a python env use 'poetry run' +# Environment +- this application normally runs on an embedded linux on a cm4 ## Application - this is a bluetooth Auracast transmitter application diff --git a/src/service/update_and_run_server_and_frontend.sh b/src/service/update_and_run_server_and_frontend.sh index 7dc42af..d9b9cd9 100644 --- a/src/service/update_and_run_server_and_frontend.sh +++ b/src/service/update_and_run_server_and_frontend.sh @@ -4,6 +4,14 @@ set -e # This script installs, enables, and restarts the auracast-server and auracast-frontend services # Requires sudo privileges +# Ensure static fallback IP is configured on eth0 (for direct laptop connection) +FALLBACK_IP="192.168.42.10/24" +if ! nmcli -g ipv4.addresses con show "Wired connection 1" 2>/dev/null | grep -q "$FALLBACK_IP"; then + echo "Adding static fallback IP $FALLBACK_IP to eth0..." + sudo nmcli con modify "Wired connection 1" +ipv4.addresses "$FALLBACK_IP" + sudo nmcli con up "Wired connection 1" +fi + # Copy system service file for frontend sudo cp /home/caster/bumble-auracast/src/service/auracast-frontend.service /etc/systemd/system/auracast-frontend.service