Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

limiter.toml does not exist when setting server.limiter: true #5

Open
thaynes43 opened this issue Aug 29, 2024 · 1 comment
Open

limiter.toml does not exist when setting server.limiter: true #5

thaynes43 opened this issue Aug 29, 2024 · 1 comment

Comments

@thaynes43
Copy link

Hello,

Posting for awareness if anyone else encounters this. When I set server.limiter: true I started seeing errors that limiter.toml did not exist and going into the container I did not find it at /etc/serxng. I created a ConfigMap with this value:

apiVersion: v1
kind: ConfigMap
metadata:
  name: configmap-searxng-limiter
  namespace: haynes-intelligence
data:
  limiter.toml: |
    # This configuration file updates the default configuration file
    # See https://github.com/searxng/searxng/blob/master/searx/limiter.toml
    [botdetection.ip_limit]
    link_token = true

And then configured persistence to plop it where the service was looking for it:

    persistence:
      limiter:
        enabled: true
        type: configMap
        name: configmap-searxng-limiter
        mountPath: /etc/searxng/limiter.toml
        subPath: limiter.toml

And it is now there, errors are gone:

/etc/searxng # ls
limiter.toml  settings.yml  uwsgi.ini

And the contents match the map:

/etc/searxng # cat limiter.toml 
# This configuration file updates the default configuration file
# See https://github.com/searxng/searxng/blob/master/searx/limiter.toml
[botdetection.ip_limit]
link_token = true/etc/searxng # 

For reference here are the settings I configured as well to get the limiter working:

/etc/searxng # cat settings.yml 
redis:
  url: redis://searxng-redis:6379
search:
  formats:
  - html
  - json
server:
  limiter: true
  secret_key: $SEARXNG_SECRET

I am using this for Open WebUI which also required - json as a format.

Thanks!

@unixfox
Copy link
Member

unixfox commented Jan 3, 2025

Could you create a PR please in order to fix the bug?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants