diff --git a/restart.sh b/restart.sh index d81d548a2c..e2d0da0eaa 100755 --- a/restart.sh +++ b/restart.sh @@ -75,6 +75,10 @@ if [ $? -ne 0 ]; then fi echo "" +# Garante que a porta está livre antes de iniciar (build pode ter ocupado) +fuser -k $PORT/tcp 2>/dev/null +sleep 1 + echo "🚀 Iniciando servidor na porta $PORT..." LOG_FILE="/tmp/omniroute.log" > "$LOG_FILE"