3 if [ -z "$SERVICE_IP" ]; then
4 export SERVICE_IP=`hostname -i`
6 echo "SERVICE_IP=$SERVICE_IP"
8 if [ -z "$MYSQL_ROOT_PASSWORD" ]; then
9 export MYSQL_ROOT_PASSWORD="root"
11 echo "MYSQL_ROOT_PASSWORD=$MYSQL_ROOT_PASSWORD"
13 if [ -z "$MSB_ADDR" ]; then
14 echo "Missing required variable MSB_ADDR: Microservices Service Bus address <ip>:<port>"
17 echo "MSB_ADDR=$MSB_ADDR"
19 # Wait for MSB initialization
20 echo "Wait for MSB initialization"
22 curl -sS -m 1 $MSB_ADDR > /dev/null && break
26 # Configure service based on docker environment variables
27 vfc/nfvo/lcm/docker/instance_config.sh
29 # microservice-specific one-time initialization
30 vfc/nfvo/lcm/docker/instance_init.sh
34 # Start the microservice
35 vfc/nfvo/lcm/docker/instance_run.sh