diff --git a/bin/publish-node.sh b/bin/publish-node.sh index bdcc32d..5899f04 100644 --- a/bin/publish-node.sh +++ b/bin/publish-node.sh @@ -7,7 +7,7 @@ PUBLISH_NODE_TTL=${PUBLISH_NODE_TTL:-120} PUBLISH_NODE_POLL=${PUBLISH_NODE_POLL:-60s} NODE=$(cat /var/lib/rabbitmq/nodename) -HOST_IP=${HOST_IP:-$(/sbin/ifconfig eth0 | grep 'inet addr:' | cut -d: -f2 | awk '{ print $1}')} +HOST_IP=${HOST_IP:-$(hostname -I | tr -d '[[:space:]]')} while supervisorctl status rabbitmq-server | grep 'RUNNING' do