I am trying to set up a Search Engine using Docker-Compose, Django and Solr on a web server. In this instance, I am using Solr 4.10.
My issue is that while I can get the Solr service, the database and the Django application set up correctly, the Solr service is refusing connections to it. Any attempt to access Solr admin panel from my IP address has the Admin panel not load at all but not timeout either, meaning my page hangs on waiting for the Solr panel to send a reply.
I found out from this question that if I was forward ports, I would be able to access the admin panel on http://localhost:8983/solr/. So this leads me to assume that it is refusing all external connections.
I tried out a method specified here for only allowing specific IP addresses (which I would want anyway) but this does not seem to work either as my connection is still refused on both ends.
For reference, my Solr container uses Jetty and here is my docker-compose.yml:
solr:
build: /home/ubuntu/search_engine_foodily_solr/SOLR_4.10/.
ports:
- "8983:8983"
volumes:
- /home/ubuntu/search_engine_foodily_solr/schema.xml
db:
image: postgres:latest
environment:
POSTGRES_PASSWORD: searcher
POSTGRES_USER: searcher
volumes:
- ./backups:/home/backups
web:
build: .
command: bash -c "sleep 5 && python -u search_engine/manage.py runserver 0.0.0.0:8080"
volumes:
- .:/code
- ../static:/code/static
ports:
- "80:8080"
links:
- db
- solr
environment:
- PYTHONUNBUFFERED=0