on master help sign in
[fix] buildprocess of docs in LXC (containers)

The $DOCS_BUILD variable (like all BUILD variables) in the lxc environment:: sudo -H ./utils/lxc.sh cmd searx-archlinux make docs is different from running build process in the HOST:: make docs with kernel-include directive we can use the environment variables in the reST documents to address the correct file location of the include. Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>

commitbfef2c3b65aea8dd3485e0959e068d460577a841 authorMarkus Heiser <markus.heiser@darmarit.de> dateThu 18 Jun 2020, 18:52 (6 years ago) parentaa5f947
5 files changed+26−26
docs/admin/buildhosts.rst+2−2 docs/admin/installation-searx.rst+7−7 docs/admin/installation-uwsgi.rst+9−9 docs/utils/filtron.sh.rst+4−4 docs/utils/morty.sh.rst+4−4
docs/admin/buildhosts.rst+2−2
@@ -21,13 +21,13 @@ on build hosts (see :ref:`searx.sh`).::
2121
2222This will install packages needed by searx:
2323
24−.. include:: ../../build/docs/includes/searx.rst
24+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
2525 :start-after: START distro-packages
2626 :end-before: END distro-packages
2727
2828and packages needed to build docuemtation and run tests:
2929
30−.. include:: ../../build/docs/includes/searx.rst
30+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
3131 :start-after: START build-packages
3232 :end-before: END build-packages
3333
docs/admin/installation-searx.rst+7−7
@@ -17,7 +17,7 @@ universe repository.
1717Install packages
1818================
1919
20−.. include:: ../../build/docs/includes/searx.rst
20+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
2121 :start-after: START distro-packages
2222 :end-before: END distro-packages
2323
@@ -30,7 +30,7 @@ Install packages
3030Create user
3131===========
3232
33−.. include:: ../../build/docs/includes/searx.rst
33+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
3434 :start-after: START create user
3535 :end-before: END create user
3636
@@ -41,13 +41,13 @@ install searx & dependencies
4141
4242Start a interactive shell from new created user and clone searx:
4343
44−.. include:: ../../build/docs/includes/searx.rst
44+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
4545 :start-after: START clone searx
4646 :end-before: END clone searx
4747
4848In the same shell create *virtualenv*:
4949
50−.. include:: ../../build/docs/includes/searx.rst
50+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
5151 :start-after: START create virtualenv
5252 :end-before: END create virtualenv
5353
@@ -55,7 +55,7 @@ To install searx's dependencies, exit the searx *bash* session you opened above
5555and restart a new. Before install, first check if your *virualenv* was sourced
5656from the login (*~/.profile*):
5757
58−.. include:: ../../build/docs/includes/searx.rst
58+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
5959 :start-after: START manage.sh update_packages
6060 :end-before: END manage.sh update_packages
6161
@@ -71,7 +71,7 @@ Create a copy of the :origin:`searx/settings.yml` configuration file in system's
7171*/etc* folder. Configure like shown below -- replace ``searx@\$(uname -n)`` with
7272a name of your choice -- *and/or* edit ``/etc/searx/settings.yml`` if necessary.
7373
74−.. include:: ../../build/docs/includes/searx.rst
74+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
7575 :start-after: START searx config
7676 :end-before: END searx config
7777
@@ -82,7 +82,7 @@ To check your searx setup, optional enable debugging and start the *webapp*.
8282Searx looks at the exported environment ``$SEARX_SETTINGS_PATH`` for a
8383configuration file.
8484
85−.. include:: ../../build/docs/includes/searx.rst
85+.. kernel-include:: $DOCS_BUILD/includes/searx.rst
8686 :start-after: START check searx installation
8787 :end-before: END check searx installation
8888
docs/admin/installation-uwsgi.rst+9−9
@@ -104,21 +104,21 @@ restart the uwsgi application.
104104
105105 .. group-tab:: Ubuntu / debian
106106
107− .. literalinclude:: ../../build/docs/includes/searx.rst
107+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
108108 :start-after: START searx uwsgi-description ubuntu-20.04
109109 :end-before: END searx uwsgi-description ubuntu-20.04
110110
111111
112112 .. group-tab:: Arch Linux
113113
114− .. literalinclude:: ../../build/docs/includes/searx.rst
114+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
115115 :start-after: START searx uwsgi-description arch
116116 :end-before: END searx uwsgi-description arch
117117
118118
119119 .. group-tab:: Fedora / RHEL
120120
121− .. literalinclude:: ../../build/docs/includes/searx.rst
121+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
122122 :start-after: START searx uwsgi-description fedora
123123 :end-before: END searx uwsgi-description fedora
124124
@@ -127,22 +127,22 @@ restart the uwsgi application.
127127
128128 .. group-tab:: Ubuntu / debian
129129
130− .. literalinclude:: ../../build/docs/includes/searx.rst
131− :language: ini
130+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
131+ :code: ini
132132 :start-after: START searx uwsgi-appini ubuntu-20.04
133133 :end-before: END searx uwsgi-appini ubuntu-20.04
134134
135135 .. group-tab:: Arch Linux
136136
137− .. literalinclude:: ../../build/docs/includes/searx.rst
138− :language: ini
137+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
138+ :code: ini
139139 :start-after: START searx uwsgi-appini arch
140140 :end-before: END searx uwsgi-appini arch
141141
142142 .. group-tab:: Fedora / RHEL
143143
144− .. literalinclude:: ../../build/docs/includes/searx.rst
145− :language: ini
144+ .. kernel-include:: $DOCS_BUILD/includes/searx.rst
145+ :code: ini
146146 :start-after: START searx uwsgi-appini fedora
147147 :end-before: END searx uwsgi-appini fedora
148148
docs/utils/filtron.sh.rst+4−4
@@ -41,7 +41,7 @@ into this user account:
4141Create user
4242===========
4343
44−.. include:: ../../build/docs/includes/filtron.rst
44+.. kernel-include:: $DOCS_BUILD/includes/filtron.rst
4545 :start-after: START create user
4646 :end-before: END create user
4747
@@ -49,7 +49,7 @@ Create user
4949Install go
5050==========
5151
52−.. include:: ../../build/docs/includes/filtron.rst
52+.. kernel-include:: $DOCS_BUILD/includes/filtron.rst
5353 :start-after: START install go
5454 :end-before: END install go
5555
@@ -61,11 +61,11 @@ Install :origin:`rules.json <utils/templates/etc/filtron/rules.json>` at
6161``/etc/filtron/rules.json`` (see :ref:`Sample configuration of filtron`) and
6262install filtron software and systemd unit:
6363
64−.. include:: ../../build/docs/includes/filtron.rst
64+.. kernel-include:: $DOCS_BUILD/includes/filtron.rst
6565 :start-after: START install filtron
6666 :end-before: END install filtron
6767
68−.. include:: ../../build/docs/includes/filtron.rst
68+.. kernel-include:: $DOCS_BUILD/includes/filtron.rst
6969 :start-after: START install systemd unit
7070 :end-before: END install systemd unit
7171
docs/utils/morty.sh.rst+4−4
@@ -42,7 +42,7 @@ into this user account:
4242Create user
4343===========
4444
45−.. include:: ../../build/docs/includes/morty.rst
45+.. kernel-include:: $DOCS_BUILD/includes/morty.rst
4646 :start-after: START create user
4747 :end-before: END create user
4848
@@ -50,7 +50,7 @@ Create user
5050Install go
5151==========
5252
53−.. include:: ../../build/docs/includes/morty.rst
53+.. kernel-include:: $DOCS_BUILD/includes/morty.rst
5454 :start-after: START install go
5555 :end-before: END install go
5656
@@ -60,11 +60,11 @@ Install morty
6060
6161Install morty software and systemd unit:
6262
63−.. include:: ../../build/docs/includes/morty.rst
63+.. kernel-include:: $DOCS_BUILD/includes/morty.rst
6464 :start-after: START install morty
6565 :end-before: END install morty
6666
67−.. include:: ../../build/docs/includes/morty.rst
67+.. kernel-include:: $DOCS_BUILD/includes/morty.rst
6868 :start-after: START install systemd unit
6969 :end-before: END install systemd unit
7070