1
0

[HUDI-501] Execute docker/setup_demo.sh in any directory

This commit is contained in:
yuehan124
2020-01-06 15:21:55 +08:00
committed by Balaji Varadarajan
parent 8f935e779a
commit c78092d2d3
2 changed files with 8 additions and 6 deletions

View File

@@ -18,12 +18,13 @@
# limitations under the License. # limitations under the License.
################################################################################ ################################################################################
WS_ROOT=`dirname $PWD` SCRIPT_PATH=$(cd `dirname $0`; pwd)
WS_ROOT=`dirname $SCRIPT_PATH`
# restart cluster # restart cluster
HUDI_WS=${WS_ROOT} docker-compose -f compose/docker-compose_hadoop284_hive233_spark244.yml down HUDI_WS=${WS_ROOT} docker-compose -f ${SCRIPT_PATH}/compose/docker-compose_hadoop284_hive233_spark244.yml down
HUDI_WS=${WS_ROOT} docker-compose -f compose/docker-compose_hadoop284_hive233_spark244.yml pull HUDI_WS=${WS_ROOT} docker-compose -f ${SCRIPT_PATH}/compose/docker-compose_hadoop284_hive233_spark244.yml pull
sleep 5 sleep 5
HUDI_WS=${WS_ROOT} docker-compose -f compose/docker-compose_hadoop284_hive233_spark244.yml up -d HUDI_WS=${WS_ROOT} docker-compose -f ${SCRIPT_PATH}/compose/docker-compose_hadoop284_hive233_spark244.yml up -d
sleep 15 sleep 15
docker exec -it adhoc-1 /bin/bash /var/hoodie/ws/docker/demo/setup_demo_container.sh docker exec -it adhoc-1 /bin/bash /var/hoodie/ws/docker/demo/setup_demo_container.sh

View File

@@ -18,10 +18,11 @@
# limitations under the License. # limitations under the License.
################################################################################ ################################################################################
SCRIPT_PATH=$(cd `dirname $0`; pwd)
# set up root directory # set up root directory
WS_ROOT=`dirname $PWD` WS_ROOT=`dirname $SCRIPT_PATH`
# shut down cluster # shut down cluster
HUDI_WS=${WS_ROOT} docker-compose -f compose/docker-compose_hadoop284_hive233_spark244.yml down HUDI_WS=${WS_ROOT} docker-compose -f ${SCRIPT_PATH}/compose/docker-compose_hadoop284_hive233_spark244.yml down
# remove houst mount directory # remove houst mount directory
rm -rf /tmp/hadoop_data rm -rf /tmp/hadoop_data