mirror of
https://github.com/searxng/searxng.git
synced 2025-12-22 19:50:00 +00:00
docs: rework of chapter "Install with apache"
BTW: normalize installation-nginx.rst
This commit is contained in:
12
utils/lib.sh
12
utils/lib.sh
@@ -634,9 +634,15 @@ if [[ -z "${APACHE_SITES_AVAILABE}" ]]; then
|
||||
fi
|
||||
|
||||
apache_is_installed() {
|
||||
(command -v apachectl \
|
||||
&& command -v a2ensite \
|
||||
&& command -v a2dissite ) &>/dev/null
|
||||
case $DIST_ID-$DIST_VERS in
|
||||
ubuntu-*|debian-*)
|
||||
(command -v apachectl \
|
||||
&& command -v a2ensite \
|
||||
&& command -v a2dissite ) &>/dev/null
|
||||
;;
|
||||
arch) (command -v httpd) ;;
|
||||
fedora) (command -v httpd) ;;
|
||||
esac
|
||||
}
|
||||
|
||||
apache_reload() {
|
||||
|
||||
@@ -735,6 +735,11 @@ This installs the searx uwsgi app as apache site. If your server is public to
|
||||
the internet, you should instead use a reverse proxy (filtron) to block
|
||||
excessively bot queries."
|
||||
|
||||
case $DIST_ID-$DIST_VERS in
|
||||
ubuntu-*|debian-*) : ;;
|
||||
*) err_msg "sorry distro $DIST_ID $DIST_VERS not yet supported"; exit 42 ;;
|
||||
esac
|
||||
|
||||
! apache_is_installed && err_msg "Apache is not installed."
|
||||
|
||||
if ! ask_yn "Do you really want to install apache site for searx-uwsgi?"; then
|
||||
|
||||
@@ -18,8 +18,8 @@ ProxyPreserveHost On
|
||||
ProxyPass http://${MORTY_LISTEN}
|
||||
RequestHeader set X-Script-Name ${PUBLIC_URL_PATH_MORTY}
|
||||
|
||||
# In Apache it seems, that setting HTTP_HOST header direct here does have no
|
||||
# effect. I needed to set 'ProxyPreserveHost On' (see above).
|
||||
# In Apache it seems, that setting HTTP_HOST header directive here does have
|
||||
# no effect. I needed to set 'ProxyPreserveHost On' (see above).
|
||||
|
||||
# RequestHeader set Host ${PUBLIC_HOST}
|
||||
|
||||
|
||||
@@ -23,8 +23,8 @@ ProxyPreserveHost On
|
||||
ProxyPass http://${FILTRON_LISTEN}
|
||||
RequestHeader set X-Script-Name ${FILTRON_URL_PATH}
|
||||
|
||||
# In Apache it seems, that setting HTTP_HOST header direct here does have no
|
||||
# effect. I needed to set 'ProxyPreserveHost On' (see above). HTTP_HOST
|
||||
# In Apache it seems, that setting HTTP_HOST header directive here does have
|
||||
# no effect. I needed to set 'ProxyPreserveHost On' (see above). HTTP_HOST
|
||||
# (ProxyPreserveHost On) is needed by searx to render correct *Search URL*
|
||||
# in the *Link* box and *saved preference*.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user