<feed xmlns='http://www.w3.org/2005/Atom'>
<title>searxng/.git/utils/templates/etc/uwsgi/apps-archlinux, branch master</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/'/>
<entry>
<title>[enh] py: whitenoise for static handling (#5032)</title>
<updated>2025-07-23T16:16:10+00:00</updated>
<author>
<name>Ivan Gabaldon</name>
<email>igabaldon@inetol.net</email>
</author>
<published>2025-07-23T16:16:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=42f102ce1bbcd76d49db0047d9ad141609eac946'/>
<id>42f102ce1bbcd76d49db0047d9ad141609eac946</id>
<content type='text'>
While looking at ways to better handle static files, I saw a package that replaces Flask `static_folder` functionality. Not only it's considerably faster, but already includes the capability to serve sidecars without having to intercept. This also replaces the uWSGI folder mapping functionality.

Closes https://github.com/searxng/searxng/issues/4977</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
While looking at ways to better handle static files, I saw a package that replaces Flask `static_folder` functionality. Not only it's considerably faster, but already includes the capability to serve sidecars without having to intercept. This also replaces the uWSGI folder mapping functionality.

Closes https://github.com/searxng/searxng/issues/4977</pre>
</div>
</content>
</entry>
<entry>
<title>[mod] remove option ui.static_use_hash (cache busting) (#5004)</title>
<updated>2025-07-11T14:53:36+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarIT.de</email>
</author>
<published>2025-07-11T14:53:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=574b285efa1658fd6d82d673e2063be659d5f624'/>
<id>574b285efa1658fd6d82d673e2063be659d5f624</id>
<content type='text'>
Cache busting has caused serious problems for users in the past, here are two
examples:

- https://github.com/searxng/searxng/issues/4419
- https://github.com/searxng/searxng/issues/4481

And it makes development and deployment significantly more complex because it
binds the client side to the server side:

- https://github.com/searxng/searxng/pull/4466

In the light of a decoupled development of the WEB clients from the server side:

- https://github.com/searxng/searxng/pull/4988

is it appropriate to abandon this feature. In fact,  it has been ineffective
since #4436 anyway.

However, the benefit has always been questionable, since at best only a few kB
of data are saved (at least in the context of an image_proxy, the effect is below
the detection limit). Ultimately, the client is responsible for caching.

Related: https://github.com/searxng/searxng/issues?q=label%3A%22clear%20browser%20cache%22

Closes: https://github.com/searxng/searxng/pull/4466
Closes: https://github.com/searxng/searxng/issues/1326
Closes: https://github.com/searxng/searxng/issues/964

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Cache busting has caused serious problems for users in the past, here are two
examples:

- https://github.com/searxng/searxng/issues/4419
- https://github.com/searxng/searxng/issues/4481

And it makes development and deployment significantly more complex because it
binds the client side to the server side:

- https://github.com/searxng/searxng/pull/4466

In the light of a decoupled development of the WEB clients from the server side:

- https://github.com/searxng/searxng/pull/4988

is it appropriate to abandon this feature. In fact,  it has been ineffective
since #4436 anyway.

However, the benefit has always been questionable, since at best only a few kB
of data are saved (at least in the context of an image_proxy, the effect is below
the detection limit). Ultimately, the client is responsible for caching.

Related: https://github.com/searxng/searxng/issues?q=label%3A%22clear%20browser%20cache%22

Closes: https://github.com/searxng/searxng/pull/4466
Closes: https://github.com/searxng/searxng/issues/1326
Closes: https://github.com/searxng/searxng/issues/964

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[fix] uwsgi: don't set static-expires</title>
<updated>2025-03-08T08:08:03+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarit.de</email>
</author>
<published>2025-03-06T07:50:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=523d2a76837cc8e94f29afc490c312e6af8398a7'/>
<id>523d2a76837cc8e94f29afc490c312e6af8398a7</id>
<content type='text'>
As long we don't have a working solution for cache busting [3][4] we should not
set an expire time in thw uWSGI config.

The default procedure in every web browser is the "304 Not Modified" [2] and
this default procedure should also be sufficient for us as long as we have not
implemented a complete alternative (cache busting) / form [1]

&gt; By default uWSGI will add a Last-Modified [2] header to all static responses,
&gt; and will honor the If-Modified-Since [2] request header.

[1] https://uwsgi-docs.readthedocs.io/en/latest/StaticFiles.html#setting-the-expires-headers
[2] https://developer.mozilla.org/de/docs/Web/HTTP/Status/304
[3] https://github.com/searxng/searxng/pull/4433
[4] https://github.com/searxng/searxng/issues/964

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As long we don't have a working solution for cache busting [3][4] we should not
set an expire time in thw uWSGI config.

The default procedure in every web browser is the "304 Not Modified" [2] and
this default procedure should also be sufficient for us as long as we have not
implemented a complete alternative (cache busting) / form [1]

&gt; By default uWSGI will add a Last-Modified [2] header to all static responses,
&gt; and will honor the If-Modified-Since [2] request header.

[1] https://uwsgi-docs.readthedocs.io/en/latest/StaticFiles.html#setting-the-expires-headers
[2] https://developer.mozilla.org/de/docs/Web/HTTP/Status/304
[3] https://github.com/searxng/searxng/pull/4433
[4] https://github.com/searxng/searxng/issues/964

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Docker: add UWSGI_WORKERS and UWSGI_THREAD environment variables (#2992)</title>
<updated>2023-11-12T16:46:34+00:00</updated>
<author>
<name>Alexandre Flament</name>
<email>alex@al-f.net</email>
</author>
<published>2023-11-12T16:46:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=bd3f526859449abe7409ebdb15ba5a5ae20b346a'/>
<id>bd3f526859449abe7409ebdb15ba5a5ae20b346a</id>
<content type='text'>
* Docker: add UWSGI_WORKERS and UWSGI_THREAD.

UWSGI_WORKERS specifies the number of process.
UWSGI_THREADS specifies the number of threads.

The Docker convention is to specify the whole configuration
through environment variables. While not done in SearXNG, these two
additional variables allows admins to skip uwsgi.ini

In additional, https://github.com/searxng/preview-environments starts Docker
without additional files through searxng-helm-chat.
Each instance consumes 1Go of RAM which is a lot especially when there are a
lot of instances / pull requests.

* [scripts] add environments UWSGI_WORKERS and UWSGI_THREADS

- UWSGI_WORKERS specifies the number of process.
- UWSGI_THREADS specifies the number of threads.

Templates for uwsgi scripts can be tested by::

    UWSGI_WORKERS=8 UWSGI_THREADS=9 \
      ./utils/searxng.sh --cmd\
      eval "echo \"$(cat utils/templates/etc/uwsgi/*/searxng.ini*)\""\
      | grep "workers\|threads"

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;

---------

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
Co-authored-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Docker: add UWSGI_WORKERS and UWSGI_THREAD.

UWSGI_WORKERS specifies the number of process.
UWSGI_THREADS specifies the number of threads.

The Docker convention is to specify the whole configuration
through environment variables. While not done in SearXNG, these two
additional variables allows admins to skip uwsgi.ini

In additional, https://github.com/searxng/preview-environments starts Docker
without additional files through searxng-helm-chat.
Each instance consumes 1Go of RAM which is a lot especially when there are a
lot of instances / pull requests.

* [scripts] add environments UWSGI_WORKERS and UWSGI_THREADS

- UWSGI_WORKERS specifies the number of process.
- UWSGI_THREADS specifies the number of threads.

Templates for uwsgi scripts can be tested by::

    UWSGI_WORKERS=8 UWSGI_THREADS=9 \
      ./utils/searxng.sh --cmd\
      eval "echo \"$(cat utils/templates/etc/uwsgi/*/searxng.ini*)\""\
      | grep "workers\|threads"

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;

---------

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
Co-authored-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[fix] harmonize default settings for caching of /static files</title>
<updated>2023-09-25T20:52:23+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarit.de</email>
</author>
<published>2023-09-22T05:50:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=51bcd95a754eca6d5a3420615ac6c3c37c993702'/>
<id>51bcd95a754eca6d5a3420615ac6c3c37c993702</id>
<content type='text'>
Caching files on the client side for more than a day can confuse the end user
when updating static files[1].

Depending on the way of providing a SearXNG instance via HTTP, there are several
ways to optimize the access to the /static files.  However, since we don't know
what optimization an admin has provided for his static files, we should have
moderate settings in the defaults that run robustly in a wide variety of
installations.

In this sense, all caches on the client side should be cleared after one day at
the latest.  So far the files were cached for one year on client side; as soon
as changes are made to the static files (with the option `static_use_hash:
true`) the old static files are kept for one year on the CLient side / which can
also be evaluated as unnecessary caching.

[1] https://github.com/searxng/searxng/discussions/2821

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Caching files on the client side for more than a day can confuse the end user
when updating static files[1].

Depending on the way of providing a SearXNG instance via HTTP, there are several
ways to optimize the access to the /static files.  However, since we don't know
what optimization an admin has provided for his static files, we should have
moderate settings in the defaults that run robustly in a wide variety of
installations.

In this sense, all caches on the client side should be cleared after one day at
the latest.  So far the files were cached for one year on client side; as soon
as changes are made to the static files (with the option `static_use_hash:
true`) the old static files are kept for one year on the CLient side / which can
also be evaluated as unnecessary caching.

[1] https://github.com/searxng/searxng/discussions/2821

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>uwsgi.ini: remove unused cache2</title>
<updated>2023-08-13T05:55:05+00:00</updated>
<author>
<name>Alexandre Flament</name>
<email>alex@al-f.net</email>
</author>
<published>2023-08-11T10:37:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=4573417b6c5d50935233268d672d0f3fc8cef8c6'/>
<id>4573417b6c5d50935233268d672d0f3fc8cef8c6</id>
<content type='text'>
cache2 was used before PR #1856
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
cache2 was used before PR #1856
</pre>
</div>
</content>
</entry>
<entry>
<title>[fix] typos / reported by @kianmeng in searx PR-3366</title>
<updated>2022-09-27T16:32:14+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarit.de</email>
</author>
<published>2022-09-27T15:01:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=ba8959ad7c18ce4165d29b7a472d845bd96f4735'/>
<id>ba8959ad7c18ce4165d29b7a472d845bd96f4735</id>
<content type='text'>
[PR-3366] https://github.com/searx/searx/pull/3366

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[PR-3366] https://github.com/searx/searx/pull/3366

Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[fix] uWSGI: increase buffer-size</title>
<updated>2022-07-31T10:40:06+00:00</updated>
<author>
<name>Léon Tiekötter</name>
<email>leon@tiekoetter.com</email>
</author>
<published>2022-07-31T09:40:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=2b94fef7ec38e72acb8103634a55aabbf13e405d'/>
<id>2b94fef7ec38e72acb8103634a55aabbf13e405d</id>
<content type='text'>
Increase max size of a request, by default it is 4k [1].  4096 as buffer-size is
too small and will result in the preference urls not working.

[1] https://uwsgi-docs.readthedocs.io/en/latest/Options.html#buffer-size
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Increase max size of a request, by default it is 4k [1].  4096 as buffer-size is
too small and will result in the preference urls not working.

[1] https://uwsgi-docs.readthedocs.io/en/latest/Options.html#buffer-size
</pre>
</div>
</content>
</entry>
<entry>
<title>[utils/searxng.sh] implement new script to install SearXNG</title>
<updated>2022-07-30T11:39:35+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarit.de</email>
</author>
<published>2022-05-27T16:43:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=782f73540e2d383ea122716507ccd9582918ab51'/>
<id>782f73540e2d383ea122716507ccd9582918ab51</id>
<content type='text'>
Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[install scripts] rename SEARX_&lt;name&gt; variables to SEARXNG_&lt;name&gt;</title>
<updated>2022-07-30T11:39:35+00:00</updated>
<author>
<name>Markus Heiser</name>
<email>markus.heiser@darmarit.de</email>
</author>
<published>2022-05-27T16:41:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.slickd.xyz/searxng/.git/commit/?id=81bba4486916dbca4467a7e8c8b839a7c55c2a09'/>
<id>81bba4486916dbca4467a7e8c8b839a7c55c2a09</id>
<content type='text'>
Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Markus Heiser &lt;markus.heiser@darmarit.de&gt;
</pre>
</div>
</content>
</entry>
</feed>
