diff options
author | yangyan <yangyanyj@chinamobile.com> | 2019-03-25 15:01:42 +0800 |
---|---|---|
committer | yangyan <yangyanyj@chinamobile.com> | 2019-03-25 15:01:58 +0800 |
commit | 6ac6fa2ab9c44ce965f24435b2429421132bf5d1 (patch) | |
tree | 13727282f045d344946e1c5fb61a742fae13bdbf /docker/instance_config.sh | |
parent | 7b731ee2dce023f0a5fa922b0ce13d3f2493f18a (diff) |
change the way of create database
Change-Id: Ib75b63ebea6f444e66b1c3d5f98e5dfed058f976
Issue-ID: VFC-1312
Signed-off-by: yangyan <yangyanyj@chinamobile.com>
Diffstat (limited to 'docker/instance_config.sh')
-rwxr-xr-x | docker/instance_config.sh | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/docker/instance_config.sh b/docker/instance_config.sh index dc811d3f..073d0e6f 100755 --- a/docker/instance_config.sh +++ b/docker/instance_config.sh @@ -29,10 +29,14 @@ fi # Configure MYSQL MYSQL_IP=`echo $MYSQL_ADDR | cut -d: -f 1` MYSQL_PORT=`echo $MYSQL_ADDR | cut -d: -f 2` +MYSQL_USER=`echo $MYSQL_AUTH | cut -d: -f 1` +MYSQL_ROOT_PASSWORD=`echo $MYSQL_AUTH | cut -d: -f 2 echo "MYSQL_ADDR=$MYSQL_ADDR" sed -i "s|DB_IP.*|DB_IP = '$MYSQL_IP'|" vfc/nfvo/lcm/lcm/pub/config/config.py sed -i "s|DB_PORT.*|DB_PORT = $MYSQL_PORT|" vfc/nfvo/lcm/lcm/pub/config/config.py sed -i "s|REDIS_HOST.*|REDIS_HOST = '$MYSQL_IP'|" vfc/nfvo/lcm/lcm/pub/config/config.py +sed -i "s|DB_USER.*|DB_USER = '$MYSQL_USER'|" vfc/nfvo/lcm/lcm/pub/config/config.py +sed -i "s|DB_PASSWD.*|DB_PASSWD = '$MYSQL_ROOT_PASSWORD'|" vfc/nfvo/lcm/lcm/pub/config/config.py cat vfc/nfvo/lcm/lcm/pub/config/config.py |