From ec7795256959625eb888aa9ecda55c6e09ed7aae Mon Sep 17 00:00:00 2001 From: Lihi Wishnitzer Date: Wed, 11 Jul 2018 15:49:20 +0300 Subject: [PATCH] Fix run_dragonflow mgmt_address parameter The script run_dragonflow tried to receive the parameter --mgmt_address. However in the documentation, management_ip should be configured. This fixes mgmt_address to management_ip to match both documentation and the project's convention. Change-Id: I7e913a1c7f82dcb77c1c00b520c1c1a7b6ece41b --- doc/source/docker_install.rst | 4 ++-- tools/run_dragonflow.sh | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/doc/source/docker_install.rst b/doc/source/docker_install.rst index 7ace78be4..f021a03c6 100644 --- a/doc/source/docker_install.rst +++ b/doc/source/docker_install.rst @@ -54,9 +54,9 @@ to allow this via `selinux`. .. code-block:: bash - export DRAGONFLOW_ADDRESS=172.18.0.3 # Any free IP in the subnet + export DRAGONFLOW_IP=172.18.0.3 # Any free IP in the subnet export MANAGEMENT_IP=$(docker inspect --format "{{ .NetworkSettings.Networks.${DRAGONFLOW_NET_NAME}.Gateway }}" etcd) # Assuming you put OVS on the host - docker run --name dragonflow --net $DRAGONFLOW_NET_NAME --ip ${DRAGONFLOW_ADDRESS} dragonflow:latest --dragonflow_address ${DRAGONFLOW_ADDRESS} --db_address ${NODE1}:2379 --management_ip ${MANAGEMENT_IP} + docker run --name dragonflow --net $DRAGONFLOW_NET_NAME --ip ${DRAGONFLOW_IP} dragonflow:latest --dragonflow_ip ${DRAGONFLOW_IP} --db_ip ${NODE1}:2379 --management_ip ${MANAGEMENT_IP} * Make sure the IP was properly assigned to the container: diff --git a/tools/run_dragonflow.sh b/tools/run_dragonflow.sh index 8f5bc6896..aa285fb41 100755 --- a/tools/run_dragonflow.sh +++ b/tools/run_dragonflow.sh @@ -3,15 +3,15 @@ # First get all the arguments while test ${#} -gt 0; do case $1 in - --dragonflow_address) + --dragonflow_ip) shift - DRAGONFLOW_ADDRESS=$1 + DRAGONFLOW_IP=$1 ;; - --db_address) + --db_ip) shift - DB_ADDRESS=$1 + DB_IP=$1 ;; - --mgmt_address) + --management_ip) shift MANAGEMENT_IP=$1 ;; @@ -29,14 +29,14 @@ while test ${#} -gt 0; do shift done -# SET DRAGONFLOW_ADDRESS and DB_ADDRESS on the ini file +# SET DRAGONFLOW_IP and DB_IP on the ini file if [ ! -d /etc/dragonflow ]; then mkdir -p /etc/dragonflow fi if [ ! -e /etc/dragonflow/dragonflow.ini ]; then - sed -e "s/LOCAL_IP/$DRAGONFLOW_ADDRESS/g" etc/standalone/dragonflow.ini | \ + sed -e "s/LOCAL_IP/$DRAGONFLOW_IP/g" etc/standalone/dragonflow.ini | \ sed -e "s/MANAGEMENT_IP/$MANAGEMENT_IP/g" | \ - sed -e "s/DB_SERVER_IP/$DB_ADDRESS/g" > /etc/dragonflow/dragonflow.ini + sed -e "s/DB_SERVER_IP/$DB_IP/g" > /etc/dragonflow/dragonflow.ini fi if [ ! -e /etc/dragonflow/dragonflow_datapath_layout.yaml ]; then cp etc/dragonflow_datapath_layout.yaml /etc/dragonflow