From: Benjamin Diaz Date: Tue, 21 May 2019 18:11:49 +0000 (-0300) Subject: Adds OSMUI_SQL_DATABASE_URI env var generation to installer X-Git-Tag: v6.0.0~14^2 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=4088a9bdec94c554fe23e35ac9df482c91241de5;p=osm%2Fdevops.git Adds OSMUI_SQL_DATABASE_URI env var generation to installer Adds install of mysql deps in LWUI Dockerfile. Adds use of entrypoint script in LWUI Dockerfile Change-Id: Iab709bd534291083d4890dd33e9f3c490d11cea1 Signed-off-by: Benjamin Diaz --- diff --git a/docker/light-ui/Dockerfile b/docker/light-ui/Dockerfile index 1e54567a..29cbb743 100644 --- a/docker/light-ui/Dockerfile +++ b/docker/light-ui/Dockerfile @@ -1,6 +1,6 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y npm git python-pip nginx supervisor curl software-properties-common +RUN apt-get update && apt-get install -y npm git python-pip nginx supervisor curl software-properties-common libmysqlclient-dev mysql-client RUN npm install -g bower RUN ln -s /usr/bin/nodejs /usr/bin/node RUN echo "daemon off;" >> /etc/nginx/nginx.conf diff --git a/installers/docker/docker-compose.yaml b/installers/docker/docker-compose.yaml index f6082626..d8866e5b 100644 --- a/installers/docker/docker-compose.yaml +++ b/installers/docker/docker-compose.yaml @@ -174,5 +174,7 @@ services: OSM_SERVER: nbi #depends_on: # - nbi + env_file: + - ./lwui.env ports: - "${OSM_UI_PORTS:-80:80}" diff --git a/installers/full_install_osm.sh b/installers/full_install_osm.sh index c1380d5f..3276b143 100755 --- a/installers/full_install_osm.sh +++ b/installers/full_install_osm.sh @@ -834,6 +834,11 @@ function generate_docker_env_files() { echo "OSMPOL_SQL_DATABASE_URI=mysql://root:${MYSQL_ROOT_PASSWORD}@mysql:3306/pol" | $WORKDIR_SUDO tee -a $OSM_DOCKER_WORK_DIR/pol.env fi + # LW-UI + if [ ! -f $OSM_DOCKER_WORK_DIR/lwui.env ]; then + echo "OSMUI_SQL_DATABASE_URI=mysql://root:${MYSQL_ROOT_PASSWORD}@mysql:3306/lwui" | $WORKDIR_SUDO tee -a $OSM_DOCKER_WORK_DIR/lwui.env + fi + echo "Finished generation of docker env files" }