Skip to content
This repository was archived by the owner on Sep 28, 2021. It is now read-only.

Commit 3bd9e29

Browse files
committed
get proper environment.
1 parent 4267eb2 commit 3bd9e29

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

bin/env

+6
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ if [ ! -z "$MESOS_TASK_ID" ]; then
4343
export PEER_PORT=${PORT1}
4444
fi
4545

46+
# If we're running in Docker compose...
47+
if [ ! -z "$DOCKER_COMPOSE" ]; then
48+
export IP=$(awk 'END{print $1}' /etc/hosts)
49+
export NODE_NAME=${HOSTNAME}@${IP}
50+
fi
51+
4652
# Assume 127.0.0.1 as bind host.
4753
if [ -z "$IP" ]; then
4854
echo "IP address not set; defaulting to 127.0.0.1."

0 commit comments

Comments
 (0)