summaryrefslogtreecommitdiffstats
path: root/src/main/docker/scripts/start-zookeeper.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/docker/scripts/start-zookeeper.sh')
-rw-r--r--src/main/docker/scripts/start-zookeeper.sh2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main/docker/scripts/start-zookeeper.sh b/src/main/docker/scripts/start-zookeeper.sh
index 5222c78..9ae7a76 100644
--- a/src/main/docker/scripts/start-zookeeper.sh
+++ b/src/main/docker/scripts/start-zookeeper.sh
@@ -116,8 +116,10 @@ function create_data_dirs() {
chown -R $ZK_USER:$ZK_USER $ZK_LOG_DIR
fi
+ if [ $ZK_REPLICAS -gt 1 ]; then
echo $MY_ID >> $ID_FILE
cat $ID_FILE
+ fi
echo "Created ZooKeeper data directories and set permissions in $ZK_DATA_DIR"
}