From 1a1202abcf988a484bddbaec297ac3ab3f472537 Mon Sep 17 00:00:00 2001 From: Gilles Soulier Date: Fri, 22 May 2026 19:42:39 +0200 Subject: [PATCH] =?UTF-8?q?fix:=20valeurs=20par=20d=C3=A9faut=20install.sh?= =?UTF-8?q?=20(serveur=2010.0.0.50,=20MQTT=2010.0.0.3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 4.6 --- deploy/install.sh | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/deploy/install.sh b/deploy/install.sh index cc2f62e..cdfec81 100755 --- a/deploy/install.sh +++ b/deploy/install.sh @@ -82,18 +82,12 @@ ok "Binaire téléchargé ($(du -sh "$TMP_BIN" | cut -f1))" echo "" echo "--- Configuration du serveur ---" -if [ -z "${SERVER_IP:-}" ]; then - read -rp "Adresse IP du serveur Nanometrics : " SERVER_IP -fi -if [ -z "${SERVER_IP:-}" ]; then - err "SERVER_IP est requis." - exit 1 -fi - +SERVER_IP="${SERVER_IP:-10.0.0.50}" SERVER_PORT="${SERVER_PORT:-9999}" +MQTT_HOST="${MQTT_HOST:-10.0.0.3}" MQTT_ENABLED="${MQTT_ENABLED:-false}" -ok "Serveur : $SERVER_IP:$SERVER_PORT" +ok "Serveur : $SERVER_IP:$SERVER_PORT | MQTT broker : $MQTT_HOST" # ── 5. Installer le binaire ──────────────────────────────────────────────────── echo "" @@ -125,7 +119,7 @@ enabled = true [protocols.mqtt] enabled = $MQTT_ENABLED -host = "10.0.0.3" +host = "$MQTT_HOST" port = 1883 topic_base = "nanometrics/agents" auto_discovery = true