From 94a2d8b77565ff50462498b8646c66b69bb4a23f Mon Sep 17 00:00:00 2001 From: yangyan Date: Thu, 25 Apr 2019 17:13:29 +0800 Subject: update file directory Change-Id: I450596eb4c88e9cedb2ae705431973d1ca7e3a43 Issue-ID: MODELING-159 Signed-off-by: yangyan --- docker/Dockerfile | 2 +- docker/docker-entrypoint.sh | 6 +++--- docker/docker-env-conf.sh | 4 ++-- docker/instance_config.sh | 14 +++++++------- docker/instance_init.sh | 4 ++-- docker/instance_run.sh | 2 +- 6 files changed, 16 insertions(+), 16 deletions(-) (limited to 'docker') diff --git a/docker/Dockerfile b/docker/Dockerfile index e532e82..98bea25 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -13,4 +13,4 @@ EXPOSE 8806 USER onap WORKDIR /service -ENTRYPOINT modeling/toscaparsers/genericparser/docker/docker-entrypoint.sh +ENTRYPOINT modeling/genericparser/docker/docker-entrypoint.sh diff --git a/docker/docker-entrypoint.sh b/docker/docker-entrypoint.sh index 08cf11c..a093691 100755 --- a/docker/docker-entrypoint.sh +++ b/docker/docker-entrypoint.sh @@ -34,12 +34,12 @@ for i in {1..5}; do done # Configure service based on docker environment variables -modeling/toscaparsers/genericparser/docker/instance_config.sh +modeling/genericparser/docker/instance_config.sh # microservice-specific one-time initialization -modeling/toscaparsers/genericparser/docker/instance_init.sh +modeling/genericparser/docker/instance_init.sh date > init.log # Start the microservice -modeling/toscaparsers/genericparser/docker/instance_run.sh +modeling/genericparser/docker/instance_run.sh diff --git a/docker/docker-env-conf.sh b/docker/docker-env-conf.sh index 985aada..2629c8c 100755 --- a/docker/docker-env-conf.sh +++ b/docker/docker-env-conf.sh @@ -9,12 +9,12 @@ install_sf(){ # get binary zip from nexus - vfc-nfvo-genericparser - wget -q -O modeling-genericparser.zip 'https://nexus.onap.org/service/local/artifact/maven/redirect?r=snapshots&g=org.onap.modeling.toscaparsers.genericparser&a=modeling-toscaparsers-genericparserr&v=LATEST&e=zip' && \ + wget -q -O modeling-genericparser.zip 'https://nexus.onap.org/service/local/artifact/maven/redirect?r=snapshots&g=org.onap.modeling.genericparser&a=modeling-genericparserr&v=LATEST&e=zip' && \ unzip modeling-genericparser.zip && \ rm -rf modeling-genericparser.zip && \ pip install --upgrade setuptools pip && \ - pip install --no-cache-dir --pre -r /service/modeling/toscaparsers/genericparser/requirements.txt + pip install --no-cache-dir --pre -r /service/modeling/genericparser/requirements.txt } add_user(){ diff --git a/docker/instance_config.sh b/docker/instance_config.sh index 64bc3da..80a278f 100755 --- a/docker/instance_config.sh +++ b/docker/instance_config.sh @@ -5,15 +5,15 @@ MSB_PORT=`echo $MSB_ADDR | cut -d: -f 2` # modeling/genericparser if [ $MSB_IP ]; then - sed -i "s|MSB_SERVICE_IP.*|MSB_SERVICE_IP = '$MSB_IP'|" modeling/toscaparsers/genericparser/genericparser/pub/config/config.py + sed -i "s|MSB_SERVICE_IP.*|MSB_SERVICE_IP = '$MSB_IP'|" modeling/genericparser/genericparser/pub/config/config.py fi if [ $MSB_PORT ]; then - sed -i "s|MSB_SERVICE_PORT.*|MSB_SERVICE_PORT = '$MSB_PORT'|" modeling/toscaparsers/genericparser/genericparser/pub/config/config.py + sed -i "s|MSB_SERVICE_PORT.*|MSB_SERVICE_PORT = '$MSB_PORT'|" modeling/genericparser/genericparser/pub/config/config.py fi if [ $SERVICE_IP ]; then - sed -i "s|\"ip\": \".*\"|\"ip\": \"$SERVICE_IP\"|" modeling/toscaparsers/genericparser/genericparser/pub/config/config.py + sed -i "s|\"ip\": \".*\"|\"ip\": \"$SERVICE_IP\"|" modeling/genericparser/genericparser/pub/config/config.py fi MYSQL_IP=`echo $MYSQL_ADDR | cut -d: -f 1` @@ -27,8 +27,8 @@ else fi -sed -i "s|DB_IP.*|DB_IP = '$MYSQL_IP'|" modeling/toscaparsers/genericparser/genericparser/pub/config/config.py -sed -i "s|DB_PORT.*|DB_PORT = $MYSQL_PORT|" modeling/toscaparsers/genericparser/genericparser/pub/config/config.py -sed -i "s|REDIS_HOST.*|REDIS_HOST = '$REDIS_IP'|"modeling/toscaparsers/genericparser/genericparser/pub/config/config.py +sed -i "s|DB_IP.*|DB_IP = '$MYSQL_IP'|" modeling/genericparser/genericparser/pub/config/config.py +sed -i "s|DB_PORT.*|DB_PORT = $MYSQL_PORT|" modeling/genericparser/genericparser/pub/config/config.py +sed -i "s|REDIS_HOST.*|REDIS_HOST = '$REDIS_IP'|"modeling/genericparser/genericparser/pub/config/config.py -cat modeling/toscaparsers/genericparser/genericparser/pub/config/config.py +cat modeling/genericparser/genericparser/pub/config/config.py diff --git a/docker/instance_init.sh b/docker/instance_init.sh index ac71b43..0c25203 100755 --- a/docker/instance_init.sh +++ b/docker/instance_init.sh @@ -13,13 +13,13 @@ fi function create_database { - cd /service/modeling/toscaparsers/genericparser/resources/bin + cd /service/modeling/genericparser/resources/bin bash initDB.sh $MYSQL_ROOT_USER $MYSQL_ROOT_PASSWORD $MYSQL_PORT $MYSQL_IP } function migrate_database { - cd /service/modeling/toscaparsers/genericparser + cd /service/modeling/genericparser python manage.py migrate } diff --git a/docker/instance_run.sh b/docker/instance_run.sh index 9388135..8fce672 100755 --- a/docker/instance_run.sh +++ b/docker/instance_run.sh @@ -1,6 +1,6 @@ #!/bin/bash -cd /service/modeling/toscaparsers/genericparser +cd /service/modeling/genericparser ./run.sh -- cgit 1.2.3-korg