diff options
author | grakiss <grakiss.wanglei@huawei.com> | 2017-08-22 16:06:22 +0800 |
---|---|---|
committer | grakiss <grakiss.wanglei@huawei.com> | 2017-08-22 16:06:22 +0800 |
commit | 90bd864487045df3dcacb32ced88ab247606e482 (patch) | |
tree | 91b98306f54f680cf54f60146633b95bbd4bee94 | |
parent | 474795c11c556dcd325559853fe7ed436a69418c (diff) |
persist db file in host for mongo container
JIRA: DOVETAIL-488
Keep db file in host to avoid data lost
Change-Id: If039789eabfb8847ea344c016cb74e226be43f73
Signed-off-by: grakiss <grakiss.wanglei@huawei.com>
-rwxr-xr-x | dovetail/utils/local_db/launch_db.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dovetail/utils/local_db/launch_db.sh b/dovetail/utils/local_db/launch_db.sh index 727541c4..956ccfe8 100755 --- a/dovetail/utils/local_db/launch_db.sh +++ b/dovetail/utils/local_db/launch_db.sh @@ -50,7 +50,7 @@ fi # run mongodb container echo "Step3: run ${container_name} container." -cmd="sudo docker run -itd -p ${mongodb_port}:27017 --name ${container_name} ${mongodb_img}" +cmd="sudo docker run -itd -p ${mongodb_port}:27017 -v /home/testapi/mongo:/data/db --name ${container_name} ${mongodb_img}" echo $cmd ${cmd} |