项目作者: rokarolla

项目描述 :
Spring boot + solr
高级语言: Java
项目地址: git://github.com/rokarolla/SolrSearchService.git
创建时间: 2017-08-31T14:10:58Z
项目社区:https://github.com/rokarolla/SolrSearchService

开源协议:

下载


Running instrictions

Create Docker network

  1. docker network create --subnet=172.18.0.0/16 mynet

Run the solr on docker

  1. docker run --name my_solr --net mynet --ip 172.18.0.22 -d -p 8983:8983 -t solr

Make sure the Solr is running. Try to open an admin console http://localhost:8983/solr

Create solr Core for the application. The name should be the userIndex

  1. docker exec -it --user=solr my_solr bin/solr create_core -c userIndex

Or if you are using windows

  1. winpty docker exec -it --user=solr my_solr bin/solr create_core -c userIndex

Checkout or download the code and build an application

  1. ./gradlew build buildDocker

On windows use

  1. gradlew.bat build buildDocker

Make sure that you have an Application image on docker

  1. docker images

You should see the application in the list of the images:

  1. REPOSITORY TAG IMAGE ID CREATED SIZE
  2. matmatch/matmatch-app 1.0-SNAPSHOT de9706a8259c 2 days ago 742MB

Start the application using the same docker network

  1. docker run --name matmatch --net mynet --ip 172.18.0.23 -p 8080:8080 -t matmatch/matmatch-app:1.0-SNAPSHOT

API documentation.

The API documentation in swagger format can be found under the following URL:
http://localhost:8080/swagger-ui.html

Or in case you run the app on different host, you should replace the host name with the one where app is actually running.

If something isn’t working or you have any questions, feel free to contact me.