2020-05-04 17:28:01 +02:00
|
|
|
services:
|
2022-10-14 18:16:20 +02:00
|
|
|
|
2020-05-04 17:28:01 +02:00
|
|
|
haystack-api:
|
2022-10-14 18:16:20 +02:00
|
|
|
# Pull Haystack's latest commit
|
|
|
|
|
image: "deepset/haystack:cpu-main"
|
2020-05-04 17:28:01 +02:00
|
|
|
ports:
|
|
|
|
|
- 8000:8000
|
2021-10-27 17:07:36 +02:00
|
|
|
restart: on-failure
|
2020-05-04 17:28:01 +02:00
|
|
|
environment:
|
2022-04-12 16:41:05 +02:00
|
|
|
# See rest_api/pipeline/pipelines.haystack-pipeline.yml for configurations of Search & Indexing Pipeline.
|
2021-09-14 12:28:30 +02:00
|
|
|
- DOCUMENTSTORE_PARAMS_HOST=elasticsearch
|
2022-10-14 18:16:20 +02:00
|
|
|
- PIPELINE_YAML_PATH=/opt/venv/lib/python3.10/site-packages/rest_api/pipeline/pipelines.haystack-pipeline.yml
|
|
|
|
|
- QUERY_PIPELINE_NAME=query
|
|
|
|
|
- TOKENIZERS_PARALLELISM=false
|
2020-07-07 16:25:36 +02:00
|
|
|
depends_on:
|
2022-10-14 18:16:20 +02:00
|
|
|
elasticsearch:
|
|
|
|
|
condition: service_healthy
|
|
|
|
|
|
2020-05-04 17:28:01 +02:00
|
|
|
elasticsearch:
|
2022-10-14 18:16:20 +02:00
|
|
|
# This image is "ready-to-query" with some indexed articles
|
2021-11-25 16:23:18 +01:00
|
|
|
# about countries and capital cities from Wikipedia:
|
|
|
|
|
image: "deepset/elasticsearch-countries-and-capitals"
|
2020-07-07 16:25:36 +02:00
|
|
|
ports:
|
|
|
|
|
- 9200:9200
|
2021-10-27 17:07:36 +02:00
|
|
|
restart: on-failure
|
2020-05-04 17:28:01 +02:00
|
|
|
environment:
|
2020-12-27 18:06:09 +05:30
|
|
|
- discovery.type=single-node
|
2022-10-14 18:16:20 +02:00
|
|
|
- "ES_JAVA_OPTS=-Xms1024m -Xmx1024m"
|
|
|
|
|
healthcheck:
|
|
|
|
|
test: curl --fail http://localhost:9200/_cat/health || exit 1
|
|
|
|
|
interval: 10s
|
|
|
|
|
timeout: 1s
|
|
|
|
|
retries: 10
|
|
|
|
|
|
2020-12-27 18:06:09 +05:30
|
|
|
ui:
|
2022-10-14 18:16:20 +02:00
|
|
|
depends_on:
|
|
|
|
|
- haystack-api
|
2021-04-07 17:53:32 +02:00
|
|
|
build:
|
|
|
|
|
context: ui
|
|
|
|
|
dockerfile: Dockerfile
|
2020-12-27 18:06:09 +05:30
|
|
|
ports:
|
|
|
|
|
- 8501:8501
|
2021-10-27 17:07:36 +02:00
|
|
|
restart: on-failure
|
2020-12-27 18:06:09 +05:30
|
|
|
environment:
|
|
|
|
|
- API_ENDPOINT=http://haystack-api:8000
|
2022-10-14 18:16:20 +02:00
|
|
|
- EVAL_FILE=ui/eval_labels_example.csv
|
|
|
|
|
# The value of the following variables will be read from the host, if present.
|
2021-11-30 18:11:54 +01:00
|
|
|
# They can also be temporarily set for docker-compose, for example:
|
|
|
|
|
# DISABLE_FILE_UPLOAD=1 DEFAULT_DOCS_FROM_RETRIEVER=5 docker-compose up
|
|
|
|
|
- DISABLE_FILE_UPLOAD
|
|
|
|
|
- DEFAULT_QUESTION_AT_STARTUP
|
|
|
|
|
- DEFAULT_DOCS_FROM_RETRIEVER
|
|
|
|
|
- DEFAULT_NUMBER_OF_ANSWERS
|