Modify the request by msb with https 15/101715/2
authoryangyan <yangyanyj@chinamobile.com>
Fri, 14 Feb 2020 01:48:53 +0000 (09:48 +0800)
committerYan Yang <yangyanyj@chinamobile.com>
Fri, 14 Feb 2020 02:32:35 +0000 (02:32 +0000)
Change-Id: I6d2e40fa5e0a8d04dcc7533c8a0e76c99ce015cb
Issue-ID: VFC-1602
Signed-off-by: yangyan <yangyanyj@chinamobile.com>
lcm/docker/instance_config.sh
lcm/lcm/pub/config/config.py

index 9257c9f..6e46884 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/bash
 
+MSB_PROTO=`echo $MSB_PROTO`
 MSB_IP=`echo $MSB_ADDR | cut -d: -f 1`
 MSB_PORT=`echo $MSB_ADDR | cut -d: -f 2`
 
@@ -7,6 +8,11 @@ if [ $MSB_IP ]; then
     sed -i "s|MSB_SERVICE_IP = .*|MSB_SERVICE_IP = '$MSB_IP'|" vfc/gvnfm/vnflcm/lcm/lcm/pub/config/config.py
 fi
 
+if [ $MSB_PROTO ]; then
+    sed -i "s|MSB_SERVICE_PROTOCOL = .*|MSB_SERVICE_PROTOCOL = '$MSB_PROTO'|" vfc/gvnfm/vnflcm/lcm/lcm/pub/config/config.py
+fi
+
+
 if [ $MSB_PORT ]; then
     sed -i "s|MSB_SERVICE_PORT = .*|MSB_SERVICE_PORT = '$MSB_PORT'|" vfc/gvnfm/vnflcm/lcm/lcm/pub/config/config.py
 fi
index 27896d0..b153aee 100644 (file)
 # limitations under the License.
 
 # [MSB]
+MSB_SERVICE_PROTOCOL = 'https'
 MSB_SERVICE_IP = '127.0.0.1'
 MSB_SERVICE_PORT = '443'
-MSB_BASE_URL = "https://%s:%s" % (MSB_SERVICE_IP, MSB_SERVICE_PORT)
+MSB_BASE_URL = "%s://%s:%s" % (MSB_SERVICE_PROTOCOL, MSB_SERVICE_IP, MSB_SERVICE_PORT)
 
 # [REDIS]
 REDIS_HOST = '127.0.0.1'