Move update my.cnf to Dockerfile 27/10327/1
authorfujinhua <fu.jinhua@zte.com.cn>
Tue, 5 Sep 2017 09:40:57 +0000 (17:40 +0800)
committerfujinhua <fu.jinhua@zte.com.cn>
Tue, 5 Sep 2017 09:40:57 +0000 (17:40 +0800)
Change-Id: I3a19a5478475b8d6a72c4628ce53d3d01d8fba4a
Issue-Id: VFC-280
Signed-off-by: fujinhua <fu.jinhua@zte.com.cn>
docker/Dockerfile
docker/instance_init.sh

index e8d03b3..bcff9c5 100755 (executable)
@@ -34,6 +34,8 @@ RUN wget -q -O vfc-nfvo-lcm.zip 'https://nexus.onap.org/service/local/artifact/m
     unzip vfc-nfvo-lcm.zip && \
     rm -rf vfc-nfvo-lcm.zip
 
+RUN sed -i "s|bind-address.*|# bind-address = 127.0.0.1|" /etc/mysql/my.cnf
+
 WORKDIR /service/vfc/nfvo/lcm
 RUN pip install -r requirements.txt
 
index 3c0dcce..e8ee4bb 100755 (executable)
@@ -5,8 +5,7 @@ function start_redis_server {
 }
 
 function start_mysql {
-    sed -i "s|bind-address.*|# bind-address = 127.0.0.1|" /etc/mysql/my.cnf
-    service mysql restart
+    service mysql start
     sleep 1
 }