[docker script] skip docker mount point checking for database container (#2683)

database container doesn't mount hwsku folder.

Signed-off-by: Ying Xie <ying.xie@microsoft.com>
This commit is contained in:
Ying Xie 2019-03-19 20:14:07 -07:00 committed by Ying Xie
parent ed8e29cb6f
commit f29e6230e5

View File

@ -103,9 +103,17 @@ start() {
DOCKERCHECK=`docker inspect --type container {{docker_container_name}} 2>/dev/null`
if [ "$?" -eq "0" ]; then
{%- if docker_container_name == "database" %}
DOCKERMOUNT=""
{%- else %}
DOCKERMOUNT=`getMountPoint "$DOCKERCHECK"`
if [ "$DOCKERMOUNT" == "$HWSKU" ]; then
{%- endif %}
if [ x"$DOCKERMOUNT" == x"$HWSKU" ]; then
{%- if docker_container_name == "database" %}
echo "Starting existing {{docker_container_name}} container"
{%- else %}
echo "Starting existing {{docker_container_name}} container with HWSKU $HWSKU"
{%- endif %}
preStartAction
docker start {{docker_container_name}}
postStartAction