ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From oleew...@apache.org
Subject ambari git commit: AMBARI-22329. Log Search: Add docker compose file for Log Search server and Log Feeder (oleewere)
Date Mon, 30 Oct 2017 11:38:04 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 600b06cad -> 45be76692


AMBARI-22329. Log Search: Add docker compose file for Log Search server and Log Feeder (oleewere)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/45be7669
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/45be7669
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/45be7669

Branch: refs/heads/trunk
Commit: 45be766921cd05468fd0cd8bd3923f6d91e243af
Parents: 600b06c
Author: Oliver Szabo <oleewere@gmail.com>
Authored: Sat Oct 28 21:50:26 2017 +0200
Committer: Oliver Szabo <oleewere@gmail.com>
Committed: Sun Oct 29 03:46:03 2017 +0100

----------------------------------------------------------------------
 ambari-logsearch/docker/.gitignore              |  1 +
 ambari-logsearch/docker/Dockerfile              | 11 ++-
 ambari-logsearch/docker/all.yml                 | 40 +++++++++
 ambari-logsearch/docker/bin/start.sh            | 92 +++++++++++++++-----
 ambari-logsearch/docker/docker-compose.yml      | 89 +++++++++++++++++++
 ambari-logsearch/docker/logsearch-docker.sh     | 50 +++++++----
 ambari-logsearch/docker/logsearch-logfeeder.yml | 35 ++++++++
 ambari-logsearch/docker/logsearch-server.yml    | 35 ++++++++
 ambari-logsearch/docker/solr.yml                | 11 +--
 ambari-logsearch/docker/solr662.yml             | 37 --------
 ambari-logsearch/pom.xml                        |  1 +
 11 files changed, 317 insertions(+), 85 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/.gitignore
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/.gitignore b/ambari-logsearch/docker/.gitignore
index 99455ed..b73aed0 100644
--- a/ambari-logsearch/docker/.gitignore
+++ b/ambari-logsearch/docker/.gitignore
@@ -1 +1,2 @@
 Profile
+.env

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/Dockerfile
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/Dockerfile b/ambari-logsearch/docker/Dockerfile
index 5906a50..70e80b6 100644
--- a/ambari-logsearch/docker/Dockerfile
+++ b/ambari-logsearch/docker/Dockerfile
@@ -34,11 +34,11 @@ RUN wget --no-check-certificate -O /root/selenium-server-standalone.jar
http://s
 #Install Maven
 RUN mkdir -p /opt/maven
 WORKDIR /opt/maven
-RUN wget http://archive.apache.org/dist/maven/maven-3/3.0.5/binaries/apache-maven-3.0.5-bin.tar.gz
-RUN tar -xvzf /opt/maven/apache-maven-3.0.5-bin.tar.gz
-RUN rm -rf /opt/maven/apache-maven-3.0.5-bin.tar.gz
+RUN wget http://archive.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz
+RUN tar -xvzf /opt/maven/apache-maven-3.3.9-bin.tar.gz
+RUN rm -rf /opt/maven/apache-maven-3.3.9-bin.tar.gz
 
-ENV M2_HOME /opt/maven/apache-maven-3.0.5
+ENV M2_HOME /opt/maven/apache-maven-3.3.9
 ENV MAVEN_OPTS -Xmx2048m
 ENV PATH $PATH:$JAVA_HOME/bin:$M2_HOME/bin
 
@@ -84,5 +84,8 @@ RUN mkdir -p /var/run/ambari-logsearch-solr /var/log/ambari-logsearch-solr
/var/
 RUN cp /root/test-config/solr/solr.xml /root/logsearch_solr_index/data
 RUN cp /root/test-config/solr/zoo.cfg /root/logsearch_solr_index/data
 
+RUN mkdir -p /root/config
+RUN chmod -R 777 /root/config
+
 WORKDIR /root
 CMD /root/start.sh

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/all.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/all.yml b/ambari-logsearch/docker/all.yml
new file mode 100644
index 0000000..82f0ff9
--- /dev/null
+++ b/ambari-logsearch/docker/all.yml
@@ -0,0 +1,40 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License
+version: '3.3'
+services:
+    logsearch-all:
+        image: ambari-logsearch:v1.0
+        restart: always
+        hostname: logsearch.apache.org
+        container_name: logsearch
+        env_file:
+          - Profile
+        ports:
+          - 61888:61888
+          - 5005:5005
+          - 5006:5006
+          - 8886:8886
+          - 18886:18886
+          - 4004:4004
+          - 9983:9983
+        environment:
+          DISPLAY: $DOCKERIP:0
+        volumes:
+          - $MAVEN_REPOSITORY_LOCATION:/root/.m2
+          - $AMBARI_LOCATION:/root/ambari
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config
+          - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-logfeeder/target/classes:/root/ambari/ambari-logsearch/ambari-logsearch-logfeeder/target/package/classes
+          - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-server/target/classes/org:/root/ambari/ambari-logsearch/ambari-logsearch-server/target/package/classes/org
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/bin/start.sh
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/bin/start.sh b/ambari-logsearch/docker/bin/start.sh
index 883ba02..bea06de 100644
--- a/ambari-logsearch/docker/bin/start.sh
+++ b/ambari-logsearch/docker/bin/start.sh
@@ -20,6 +20,8 @@ LOGFEEDER_PATH=$AMBARI_PATH/ambari-logsearch/ambari-logsearch-logfeeder/target/p
 SOLR_LOCATION=/root/solr-$SOLR_VERSION.tgz
 SOLR_SERVER_LOCATION=/root/solr-$SOLR_VERSION
 ZKCLI=$SOLR_SERVER_LOCATION/server/scripts/cloud-scripts/zkcli.sh
+ZK_CONNECT_STRING=${ZK_CONNECT_STRING:-"localhost:9983"}
+COMPONENT=${COMPONENT:-"ALL"}
 
 command="$1"
 
@@ -28,23 +30,22 @@ function build_all() {
   cd $AMBARI_PATH/ambari-logsearch && mvn clean package -DskipTests && mvn
-pl ambari-logsearch-logfeeder clean package -DskipTests
 }
 
-function create_config() {
-  mkdir /root/config
-
-  mkdir /root/config/solr
-  cp /root/test-config/solr/log4j.properties /root/config/solr/
-  cp /root/test-config/solr/zoo.cfg /root/config/solr/
-  cp /root/test-config/solr/solr.xml /root/config/solr/
-  if [ $LOGSEARCH_SOLR_SSL_ENABLED == 'true' ]
-  then
-    cp /root/test-config/solr/solr-env-ssl.sh /root/config/solr/solr-env.sh
-  else
-    cp /root/test-config/solr/solr-env.sh /root/config/solr/solr-env.sh
+function set_custom_zookeeper_address() {
+  local file_to_update=${1:?"usage: <filename_to_update>"}
+  local zk_connect_string="$ZK_CONNECT_STRING"
+  if [ "$zk_connect_string" != "localhost:9983" ] ; then
+    sed -i "s|localhost:9983|$zk_connect_string|g" $file_to_update
   fi
+}
 
+function create_logfeeder_configs() {
   mkdir /root/config/logfeeder
   cp -r /root/test-config/logfeeder/* /root/config/logfeeder/
+  set_custom_zookeeper_address /root/config/logfeeder/logfeeder.properties
+  set_custom_zookeeper_address /root/config/logfeeder/shipper-conf/output.config.json
+}
 
+function create_logsearch_configs() {
   mkdir /root/config/logsearch
   cp /root/test-config/logsearch/log4j.xml /root/config/logsearch/
   cp /root/test-config/logsearch/logsearch-env.sh /root/config/logsearch/
@@ -54,8 +55,26 @@ function create_config() {
   else
     cp /root/test-config/logsearch/logsearch.properties /root/config/logsearch/logsearch.properties
   fi
+  set_custom_zookeeper_address /root/config/logsearch/logsearch.properties
+}
 
-  chmod -R 777 /root/config
+function create_solr_configs() {
+  mkdir /root/config/solr
+  cp /root/test-config/solr/log4j.properties /root/config/solr/
+  cp /root/test-config/solr/zoo.cfg /root/config/solr/
+  cp /root/test-config/solr/solr.xml /root/config/solr/
+  if [ $LOGSEARCH_SOLR_SSL_ENABLED == 'true' ]
+  then
+    cp /root/test-config/solr/solr-env-ssl.sh /root/config/solr/solr-env.sh
+  else
+    cp /root/test-config/solr/solr-env.sh /root/config/solr/solr-env.sh
+  fi
+}
+
+function create_configs() {
+  create_solr_configs
+  create_logfeeder_configs
+  create_logsearch_configs
 }
 
 function generate_keys() {
@@ -114,10 +133,43 @@ function log() {
   esac
 }
 
-create_config
-generate_keys
-start_selenium_server
-start_solr
-start_logsearch
-start_logfeeder
-log
+function main() {
+  component=${COMPONENT:-"ALL"}
+  case $component in
+    "solr")
+      create_solr_configs
+      echo "Start Solr only.."
+      export COMPONENT_LOG="solr"
+      generate_keys
+      start_solr
+      log
+     ;;
+    "logfeeder")
+      create_logfeeder_configs
+      echo "Start Log Feeder only.."
+      export COMPONENT_LOG="logfeeder"
+      generate_keys
+      start_logfeeder
+      log
+     ;;
+    "logsearch")
+      create_logsearch_configs
+      echo "Start Log Search only.."
+      export COMPONENT_LOG="logsearch"
+      generate_keys
+      start_logsearch
+      log
+     ;;
+     *)
+      create_configs
+      generate_keys
+      start_selenium_server
+      start_solr
+      start_logfeeder
+      start_logsearch
+      log
+     ;;
+  esac
+}
+
+main

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/docker-compose.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/docker-compose.yml b/ambari-logsearch/docker/docker-compose.yml
new file mode 100644
index 0000000..f988b06
--- /dev/null
+++ b/ambari-logsearch/docker/docker-compose.yml
@@ -0,0 +1,89 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License
+version: '3.3'
+services:
+  zookeeper:
+    image: zookeeper:${ZOOKEEPER_VERSION:-3.4.10}
+    restart: always
+    hostname: zoo1
+    networks:
+      - logsearch-network
+    ports:
+      - 2181:2181
+    environment:
+      ZOO_MY_ID: 1
+      ZOO_SERVERS: server.1=zookeeper:2888:3888
+  solr:
+    image: solr:${SOLR_VERSION:-6.6.2}
+    restart: always
+    hostname: solr
+    ports:
+      - "8886:8983"
+    networks:
+      - logsearch-network
+    env_file:
+      - Profile
+    entrypoint:
+      - docker-entrypoint.sh
+      - solr
+      - start
+      - "-f"
+      - "-c"
+      - "-z"
+      - ${ZOOKEEPER_CONNECTION_STRING}
+  logsearch:
+    image: ambari-logsearch:v1.0
+    restart: always
+    hostname: logsearch.apache.org
+    networks:
+      - logsearch-network
+    env_file:
+      - Profile
+    ports:
+      - 61888:61888
+      - 4444:4444
+      - 5005:5005
+    environment:
+      COMPONENT: logsearch
+      COMPONENT_LOG: logsearch
+      ZK_CONNECT_STRING: ${ZOOKEEPER_CONNECTION_STRING}
+      DISPLAY: $DOCKERIP:0
+    volumes:
+      - $AMBARI_LOCATION:/root/ambari
+      - $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
+      - $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config
+      - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-server/target/classes/org:/root/ambari/ambari-logsearch/ambari-logsearch-server/target/package/classes/org
+  logfeeder:
+    image: ambari-logsearch:v1.0
+    restart: always
+    hostname: logfeeder.apache.org
+    networks:
+      - logsearch-network
+    env_file:
+      - Profile
+    ports:
+      - 5006:5006
+    environment:
+      COMPONENT: logfeeder
+      COMPONENT_LOG: logfeeder
+      ZK_CONNECT_STRING: ${ZOOKEEPER_CONNECTION_STRING}
+    volumes:
+      - $AMBARI_LOCATION:/root/ambari
+      - $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
+      - $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config
+      - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-logfeeder/target/classes:/root/ambari/ambari-logsearch/ambari-logsearch-logfeeder/target/package/classes
+networks:
+   logsearch-network:
+      driver: bridge
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/logsearch-docker.sh
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/logsearch-docker.sh b/ambari-logsearch/docker/logsearch-docker.sh
index 1660cee..b44e7ee 100755
--- a/ambari-logsearch/docker/logsearch-docker.sh
+++ b/ambari-logsearch/docker/logsearch-docker.sh
@@ -56,20 +56,11 @@ function get_docker_ip() {
 }
 
 function start_logsearch_container() {
+  setup_env
   setup_profile
-  source $sdir/Profile
-  pushd $sdir/../../
-  local AMBARI_LOCATION=$(pwd)
-  popd
-  : ${MAVEN_REPOSITORY_LOCATION:?"Please set the MAVEN_REPOSITORY_LOCATION in Profile"}
   kill_logsearch_container
-  local docker_ip=$(get_docker_ip)
   echo "Run Log Search container"
-  docker run -d --name logsearch --hostname logsearch.apache.org -e DISPLAY=$docker_ip:0
\
-    -v $AMBARI_LOCATION:/root/ambari -v $MAVEN_REPOSITORY_LOCATION:/root/.m2 $LOGSEARCH_EXPOSED_PORTS
$LOGSEARCH_ENV_OPTS $LOGSEARCH_EXTRA_OPTS $LOGSEARCH_VOLUME_OPTS -p 9983:9983 -p 4444:4444
-p 5910:5910 \
-    -v $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-logfeeder/target/classes:/root/ambari/ambari-logsearch/ambari-logsearch-logfeeder/target/package/classes
\
-    -v $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-server/target/classes/org:/root/ambari/ambari-logsearch/ambari-logsearch-server/target/package/classes/org
\
-    ambari-logsearch:v1.0
+  docker-compose -f all.yml up -d
   ip_address=$(docker inspect --format '{{ .NetworkSettings.IPAddress }}' logsearch)
   echo "Log Search container started on $ip_address (for Mac OSX route to boot2docker/docker-machine
VM address, e.g.: 'sudo route add -net 172.17.0.0/16 192.168.59.103')"
   echo "You can follow Log Search logs with 'docker logs -f logsearch' command"
@@ -80,20 +71,45 @@ function setup_profile() {
   then
     echo "Profile file exists"
   else
-    echo "Profile does not exist, Creating a new one..."
+    echo "Profile file does not exist, Creating a new one..."
     pushd $sdir/../../
     local AMBARI_LOCATION=$(pwd)
     popd
     cat << EOF > $sdir/Profile
+COMPONENT=ALL
+COMPONENT_LOG=logsearch
+LOGFEEDER_DEBUG_SUSPEND=n
+LOGSEARCH_DEBUG_SUSPEND=n
+LOGSEARCH_HTTPS_ENABLED=false
+LOGSEARCH_SOLR_SSL_ENABLED=false
+GENERATE_KEYSTORE_AT_START=false
+EOF
+    echo "'Profile' file has been created. Check it out before starting Log Search. ($sdir/Profile)"
+    exit
+  fi;
+}
+
+function setup_env() {
+  if [ -f "$sdir/.env" ];
+  then
+    echo ".env file exists"
+  else
+    echo ".env file does not exist, Creating a new one..."
+    pushd $sdir/../../
+    local AMBARI_LOCATION=$(pwd)
+    popd
+    local docker_ip=$(get_docker_ip)
+    cat << EOF > $sdir/.env
+DOCKERIP=$docker_ip
 MAVEN_REPOSITORY_LOCATION=$HOME/.m2
-LOGSEARCH_EXPOSED_PORTS="-p 8886:8886 -p 61888:61888 -p 5005:5005 -p 5006:5006"
-LOGSEARCH_ENV_OPTS="-e LOGFEEDER_DEBUG_SUSPEND=n -e LOGSEARCH_DEBUG_SUSPEND=n -e COMPONENT_LOG=logsearch
-e LOGSEARCH_HTTPS_ENABLED=false -e LOGSEARCH_SOLR_SSL_ENABLED=false -e GENERATE_KEYSTORE_AT_START=false"
+AMBARI_LOCATION=$AMBARI_LOCATION
 
-LOGSEARCH_VOLUME_OPTS="-v $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
-v $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config"
+ZOOKEEPER_VERSION=3.4.10
+ZOOKEEPER_CONNECTION_STRING=zookeeper:2181
 
-LOGSEARCH_EXTRA_OPTS=""
+SOLR_VERSION=6.6.2
 EOF
-    echo "Profile has been created. Check it out before starting Log Search. ($sdir/Profile)"
+    echo ".env file has been created. Check it out before starting Log Search. ($sdir/.env)"
     exit
   fi;
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/logsearch-logfeeder.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/logsearch-logfeeder.yml b/ambari-logsearch/docker/logsearch-logfeeder.yml
new file mode 100644
index 0000000..4d48501
--- /dev/null
+++ b/ambari-logsearch/docker/logsearch-logfeeder.yml
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License
+version: '3.3'
+services:
+    logfeeder:
+        image: ambari-logsearch:v1.0
+        restart: always
+        networks:
+          - logsearch-network
+        env_file:
+          - Profile
+        environment:
+          COMPONENT: logfeeder
+          COMPONENT_LOG: logfeeder
+          ZK_CONNECT_STRING: ${ZOOKEEPER_CONNECTION_STRING}
+        volumes:
+          - $AMBARI_LOCATION:/root/ambari
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config
+          - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-logfeeder/target/classes:/root/ambari/ambari-logsearch/ambari-logsearch-logfeeder/target/package/classes
+networks:
+     logsearch-network:
+        driver: bridge
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/logsearch-server.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/logsearch-server.yml b/ambari-logsearch/docker/logsearch-server.yml
new file mode 100644
index 0000000..6a0d71e
--- /dev/null
+++ b/ambari-logsearch/docker/logsearch-server.yml
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License
+version: '3.3'
+services:
+    logsearch:
+        image: ambari-logsearch:v1.0
+        restart: always
+        networks:
+          - logsearch-network
+        env_file:
+          - Profile
+        environment:
+          COMPONENT: logsearch
+          COMPONENT_LOG: logsearch
+          ZK_CONNECT_STRING: ${ZOOKEEPER_CONNECTION_STRING}
+        volumes:
+          - $AMBARI_LOCATION:/root/ambari
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-logs:/root/test-logs
+          - $AMBARI_LOCATION/ambari-logsearch/docker/test-config:/root/test-config
+          - $AMBARI_LOCATION/ambari-logsearch/ambari-logsearch-server/target/classes/org:/root/ambari/ambari-logsearch/ambari-logsearch-server/target/package/classes/org
+networks:
+     logsearch-network:
+        driver: bridge
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/solr.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/solr.yml b/ambari-logsearch/docker/solr.yml
index 727aba1..f64c860 100644
--- a/ambari-logsearch/docker/solr.yml
+++ b/ambari-logsearch/docker/solr.yml
@@ -15,15 +15,12 @@
 version: '3.3'
 services:
   solr:
-    image: solr:7.1.0
+    image: solr:${SOLR_VERSION:-6.6.2}
     restart: always
-    hostname: solr
-    env_file:
-      - Profile
-    ports:
-      - "8886:8983"
     networks:
       - logsearch-network
+    env_file:
+      - Profile
     entrypoint:
       - docker-entrypoint.sh
       - solr
@@ -31,7 +28,7 @@ services:
       - "-f"
       - "-c"
       - "-z"
-      - "zoo1:2181,zoo2:2181,zoo3:2181"
+      - ${ZOOKEEPER_CONNECTION_STRING}
 networks:
    logsearch-network:
       driver: bridge
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/docker/solr662.yml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/docker/solr662.yml b/ambari-logsearch/docker/solr662.yml
deleted file mode 100644
index b0641ed..0000000
--- a/ambari-logsearch/docker/solr662.yml
+++ /dev/null
@@ -1,37 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License
-version: '3.3'
-services:
-  solr:
-    image: solr:6.6.2
-    restart: always
-    hostname: solr
-    env_file:
-      - Profile
-    ports:
-      - "8886:8983"
-    networks:
-      - logsearch-network
-    entrypoint:
-      - docker-entrypoint.sh
-      - solr
-      - start
-      - "-f"
-      - "-c"
-      - "-z"
-      - "zoo1:2181,zoo2:2181,zoo3:2181"
-networks:
-   logsearch-network:
-      driver: bridge
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/45be7669/ambari-logsearch/pom.xml
----------------------------------------------------------------------
diff --git a/ambari-logsearch/pom.xml b/ambari-logsearch/pom.xml
index 18ff45e..5efb4ba 100644
--- a/ambari-logsearch/pom.xml
+++ b/ambari-logsearch/pom.xml
@@ -171,6 +171,7 @@
             <exclude>**/src/vendor/**</exclude>
             <exclude>**/yarn.lock</exclude>
             <exclude>**/docker/Profile</exclude>
+            <exclude>**/docker/.env</exclude>
             <exclude>**/node_modules/**</exclude>
             <exclude>**/dist/**</exclude>
           </excludes>


Mime
View raw message