LibreY

- privacy respecting meta search engine
git clone git://git.acid.vegas/LibreY.git
Log | Files | Refs | Archive | README | LICENSE

commit 5e37afdd12bae5052dcf0e510f86d059e80493a5
parent f718c36e45de640e8702ae36fe3072377e94c2d8
Author: Revvy <nothingtohide@revvy.de>
Date: Thu, 31 Aug 2023 10:39:04 -0400

add cache ttl to docker

Diffstat:
Mdocker/README.md | 1+
Mdocker/attributes.sh | 1+
Mdocker/config.php | 1+

3 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/docker/README.md b/docker/README.md
@@ -85,6 +85,7 @@ This docker image was developed with high configurability in mind, so here is th
 | CONFIG_HIDDEN_SERVICE_SEARCH | false | boolean | Defines whether hidden service search will be disabled |
 | CONFIG_INSTANCE_FALLBACK | true | boolean | Choose whether or not to use the API on the backend to request to another LibreX/Y instance in case of rate limiting. |
 | CONFIG_RATE_LIMIT_COOLDOWN | 25 | integer | Time in minutes to wait before sending requests to Google again after a rate limit. |
+| CONFIG_CACHE_TIME | 20 | integer | Time in minutes to store results for in the cache. |
 
 ### Frontends
 | Variables | Default | Examples | Description |
diff --git a/docker/attributes.sh b/docker/attributes.sh
@@ -28,6 +28,7 @@ export CONFIG_BITTORRENT_TRACKERS=${CONFIG_BITTORRENT_TRACKERS:-"&tr=http://nyaa
 export CONFIG_HIDDEN_SERVICE_SEARCH=${CONFIG_HIDDEN_SERVICE_SEARCH:-false}
 export CONFIG_INSTANCE_FALLBACK="${CONFIG_INSTANCE_FALLBACK:-true}"
 export CONFIG_RATE_LIMIT_COOLDOWN="${CONFIG_RATE_LIMIT_COOLDOWN:-25}"
+export CONFIG_CACHE_TIME="${CONFIG_CACHE_TIME:-25}"
 
 # Supported apps integration configuration. These empty spaces can be set up using free hosts as pointers
 # A particular example is using the "https://yewtu.be" or a self-hosted host to integrate the invidious app to librey
diff --git a/docker/config.php b/docker/config.php
@@ -10,6 +10,7 @@
         "disable_hidden_service_search" => ${CONFIG_HIDDEN_SERVICE_SEARCH},
         "instance_fallback" => ${CONFIG_INSTANCE_FALLBACK},
         "request_cooldown" => ${CONFIG_RATE_LIMIT_COOLDOWN},
+        "cache_time" => ${CONFIG_CACHE_TIME},
 
         "frontends" => array(
             "invidious" => array(