diff options
-rw-r--r-- | azure/docker/docker-entrypoint.sh | 6 | ||||
-rw-r--r-- | azure/docker/instance-config.sh | 22 | ||||
-rw-r--r-- | azure/docker/instance-init.sh | 2 | ||||
-rw-r--r-- | azure/docker/instance-run.sh | 2 | ||||
-rw-r--r-- | azure/run.sh | 18 |
5 files changed, 25 insertions, 25 deletions
diff --git a/azure/docker/docker-entrypoint.sh b/azure/docker/docker-entrypoint.sh index 5566aff..26219d2 100644 --- a/azure/docker/docker-entrypoint.sh +++ b/azure/docker/docker-entrypoint.sh @@ -32,17 +32,17 @@ echo echo # Configure service based on docker environment variables -azure/docker/instance-config.sh +multicloud_azure/docker/instance-config.sh # Perform one-time config if [ ! -e init.log ]; then # microservice-specific one-time initialization - azure/docker/instance-init.sh + multicloud_azure/docker/instance-init.sh date > init.log fi # Start the microservice -azure/docker/instance-run.sh +multicloud_azure/docker/instance-run.sh diff --git a/azure/docker/instance-config.sh b/azure/docker/instance-config.sh index 6500d03..f3b98b0 100644 --- a/azure/docker/instance-config.sh +++ b/azure/docker/instance-config.sh @@ -16,12 +16,12 @@ # Configure MSB IP address MSB_IP=`echo $MSB_ADDR | cut -d: -f 1` MSB_PORT=`echo $MSB_PORT | cut -d: -f 2` -sed -i "s|MSB_SERVICE_IP.*|MSB_SERVICE_IP = '$MSB_IP'|" azure/azure/pub/config/config.py -sed -i "s|MSB_SERVICE_PORT.*|MSB_SERVICE_PORT = '$MSB_PORT'|" azure/azure/pub/config/config.py -sed -i "s|DB_NAME.*|DB_NAME = 'inventory'|" azure/azure/pub/config/config.py -sed -i "s|DB_USER.*|DB_USER = 'inventory'|" azure/azure/pub/config/config.py -sed -i "s|DB_PASSWD.*|DB_PASSWD = 'inventory'|" azure/azure/pub/config/config.py -sed -i "s|\"ip\": \".*\"|\"ip\": \"$SERVICE_IP\"|" azure/azure/pub/config/config.py +sed -i "s|MSB_SERVICE_IP.*|MSB_SERVICE_IP = '$MSB_IP'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|MSB_SERVICE_PORT.*|MSB_SERVICE_PORT = '$MSB_PORT'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|DB_NAME.*|DB_NAME = 'inventory'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|DB_USER.*|DB_USER = 'inventory'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|DB_PASSWD.*|DB_PASSWD = 'inventory'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|\"ip\": \".*\"|\"ip\": \"$SERVICE_IP\"|" multicloud_azure/multicloud_azure/pub/config/config.py # Configure MYSQL if [ -z "$MYSQL_ADDR" ]; then @@ -33,13 +33,13 @@ else MYSQL_PORT=`echo $MYSQL_ADDR | cut -d: -f 2` fi echo "MYSQL_ADDR=$MYSQL_ADDR" -sed -i "s|DB_IP.*|DB_IP = '$MYSQL_IP'|" azure/azure/pub/config/config.py -sed -i "s|DB_PORT.*|DB_PORT = $MYSQL_PORT|" azure/azure/pub/config/config.py +sed -i "s|DB_IP.*|DB_IP = '$MYSQL_IP'|" multicloud_azure/multicloud_azure/pub/config/config.py +sed -i "s|DB_PORT.*|DB_PORT = $MYSQL_PORT|" multicloud_azure/multicloud_azure/pub/config/config.py -cat azure/azure/pub/config/config.py +cat multicloud_azure/multicloud_azure/pub/config/config.py -sed -i "s/sip=.*/sip=$SERVICE_IP/g" azure/run.sh -sed -i "s/sip=.*/sip=$SERVICE_IP/g" azure/stop.sh +sed -i "s/sip=.*/sip=$SERVICE_IP/g" multicloud_azure/run.sh +sed -i "s/sip=.*/sip=$SERVICE_IP/g" multicloud_azure/stop.sh # Create log directory logDir="/var/log/onap/multicloud/azure" diff --git a/azure/docker/instance-init.sh b/azure/docker/instance-init.sh index cd2222c..304bdd5 100644 --- a/azure/docker/instance-init.sh +++ b/azure/docker/instance-init.sh @@ -17,6 +17,6 @@ #./bin/initDB.sh root rootpass 3306 127.0.0.1 # Install python requirements -cd /opt/azure +cd /opt/multicloud_azure ./initialize.sh cd /opt diff --git a/azure/docker/instance-run.sh b/azure/docker/instance-run.sh index 90d3e9d..10fd81e 100644 --- a/azure/docker/instance-run.sh +++ b/azure/docker/instance-run.sh @@ -13,7 +13,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -cd ./azure +cd ./multicloud_azure ./run.sh while [ ! -f /var/log/onap/multicloud/azure/azure.log ]; do diff --git a/azure/run.sh b/azure/run.sh index 5ec19e2..babf0c9 100644 --- a/azure/run.sh +++ b/azure/run.sh @@ -13,15 +13,15 @@ # See the License for the specific language governing permissions and # limitations under the License. -sed -i "s/MSB_SERVICE_IP =.*/MSB_SERVICE_IP = \"${MSB_ADDR}\"/g" azure/pub/config/config.py -sed -i "s/MSB_SERVICE_PORT =.*/MSB_SERVICE_PORT = \"${MSB_PORT}\"/g" azure/pub/config/config.py -sed -i "s/AAI_ADDR =.*/AAI_ADDR = \"${AAI_ADDR}\"/g" azure/pub/config/config.py -sed -i "s/AAI_PORT =.*/AAI_PORT = \"${AAI_PORT}\"/g" azure/pub/config/config.py -sed -i "s/AAI_SCHEMA_VERSION =.*/AAI_SCHEMA_VERSION = \"${AAI_SCHEMA_VERSION}\"/g" azure/pub/config/config.py -sed -i "s/AAI_USERNAME =.*/AAI_USERNAME = \"${AAI_USERNAME}\"/g" azure/pub/config/config.py -sed -i "s/AAI_PASSWORD =.*/AAI_PASSWORD = \"${AAI_PASSWORD}\"/g" azure/pub/config/config.py -sed -i "s/MR_ADDR =.*/MR_ADDR = \"${MR_ADDR}\"/g" azure/pub/config/config.py -sed -i "s/MR_PORT =.*/MR_PORT = \"${MR_PORT}\"/g" azure/pub/config/config.py +sed -i "s/MSB_SERVICE_IP =.*/MSB_SERVICE_IP = \"${MSB_ADDR}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/MSB_SERVICE_PORT =.*/MSB_SERVICE_PORT = \"${MSB_PORT}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/AAI_ADDR =.*/AAI_ADDR = \"${AAI_ADDR}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/AAI_PORT =.*/AAI_PORT = \"${AAI_PORT}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/AAI_SCHEMA_VERSION =.*/AAI_SCHEMA_VERSION = \"${AAI_SCHEMA_VERSION}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/AAI_USERNAME =.*/AAI_USERNAME = \"${AAI_USERNAME}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/AAI_PASSWORD =.*/AAI_PASSWORD = \"${AAI_PASSWORD}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/MR_ADDR =.*/MR_ADDR = \"${MR_ADDR}\"/g" multicloud_azure/pub/config/config.py +sed -i "s/MR_PORT =.*/MR_PORT = \"${MR_PORT}\"/g" multicloud_azure/pub/config/config.py logDir="/var/log/onap/multicloud/azure" |