diff --git a/docs/.howto b/docs/.howto index a7b52d0..b0dcca9 100644 --- a/docs/.howto +++ b/docs/.howto @@ -1,6 +1,6 @@ ## BUILD # cd docs -# docker build --tag sphinx-doc-build . +# docker build --tag rhodecode/sphinx-doc-build . # Build Docs -# docker run --rm -v $PWD:/project --workdir=/project/docs sphinx-doc-build make clean html \ No newline at end of file +# docker run --rm -v $PWD:/project --workdir=/project/docs rhodecode/sphinx-doc-build make clean html \ No newline at end of file diff --git a/docs/Dockerfile b/docs/Dockerfile index 01b328f..3d32407 100644 --- a/docs/Dockerfile +++ b/docs/Dockerfile @@ -1,5 +1,24 @@ -FROM sphinxdoc/sphinx +FROM python:3.12.0-bullseye WORKDIR /project + +RUN apt-get update \ + && apt-get install --no-install-recommends --yes \ + curl \ + zip \ + graphviz \ + imagemagick \ + make \ + && apt-get autoremove \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +RUN \ + python3 -m pip install --no-cache-dir --upgrade pip && \ + python3 -m pip install --no-cache-dir Sphinx Pillow + ADD requirements_docs.txt /project -RUN pip3 install -r requirements_docs.txt +RUN \ + python3 -m pip install -r requirements_docs.txt + +CMD ["sphinx-build", "-M", "html", ".", "_build"] diff --git a/docs/requirements_docs.txt b/docs/requirements_docs.txt index cff6677..fe17363 100644 --- a/docs/requirements_docs.txt +++ b/docs/requirements_docs.txt @@ -5,3 +5,7 @@ sphinx-press-theme==0.8.0 sphinx-rtd-theme==1.3.0 pygments==2.16.1 + +docutils<0.19 +markupsafe==2.1.3 +jinja2==3.1.2 diff --git a/docs/source/configuration/configuration-of-components.rst b/docs/source/configuration/configuration-of-components.rst index 2712c2a..1554fd1 100644 --- a/docs/source/configuration/configuration-of-components.rst +++ b/docs/source/configuration/configuration-of-components.rst @@ -59,3 +59,53 @@ By editing :file:`.custom/docker-compose-services.override.yaml` # to disable set replicas to 0 deploy: replicas: 0 + + +Disable ElasticSearch ++++++++++++++++++++++ + +ElasticSearch is used by default as a search engine. +Elasticsearch is powerful search engine, however it generally requires a lot of resource to be functional. + +In case the plan is to use CE edition, or the machine is restricted with resource ElasticSearch can be disabled. + +By editing :file:`.custom/docker-compose-services.override.yaml` + + +.. code-block:: yaml + + + version: '3.9' + ## This is a final override file for services stack + ## Add your own customizations + + ## set elasticsearch replicas to 0 to stop running it together with services stack. + services: + + elasticsearch: + # to disable set replicas to 0 + deploy: + replicas: 0 + + +Elasticsearch is used by default as a search engine inside the rhodecode.ini configuration. +So this needs to be also adjusted. + + +By editing :file:`config/_shared/rhodecode.ini` + +Turn of ElasticSearch and enable Whoosh + +.. code-block:: ini + + ; ElasticSearch (EE edition only). Requires Elastic Search cluster + ; to be installed, and running. Recommended for large amount of repositories + #search.module = rc_elasticsearch + #search.location = http://elasticsearch:9200 + ; specify Elastic Search version, 6 for latest or 2 for legacy + #search.es_version = 6 + + ; WHOOSH Backend, doesn't require additional services to run + ; it works good with few dozen repos + search.module = rhodecode.lib.index.whoosh + search.location = /var/opt/rhodecode_data/index