From 731188f2dbc7b4f6333eb3dfde5c8968f2f84eb4 Mon Sep 17 00:00:00 2001 From: askiiart Date: Wed, 1 Mar 2023 19:24:34 -0600 Subject: [PATCH] Fix whoogle compose file, update its README --- examples/whoogle/README.md | 2 +- examples/whoogle/docker-compose.yml | 54 +++++++++++++++++++++++++---- 2 files changed, 48 insertions(+), 8 deletions(-) diff --git a/examples/whoogle/README.md b/examples/whoogle/README.md index a6aef6f..570ca40 100644 --- a/examples/whoogle/README.md +++ b/examples/whoogle/README.md @@ -1,3 +1,3 @@ # References -- https://hub.docker.com/r/benbusby/whoogle-search \ No newline at end of file +- https://github.com/benbusby/whoogle-search/blob/main/docker-compose.yml \ No newline at end of file diff --git a/examples/whoogle/docker-compose.yml b/examples/whoogle/docker-compose.yml index 7b215cc..998c2ab 100644 --- a/examples/whoogle/docker-compose.yml +++ b/examples/whoogle/docker-compose.yml @@ -1,8 +1,48 @@ -version: '3.3' +# can't use mem_limit in a 3.x docker-compose file in non swarm mode +# see https://github.com/docker/compose/issues/4513 +version: "2.4" + services: - whoogle-search: - ports: - - '5000:5000' - container_name: whoogle-search - image: 'benbusby/whoogle-search:latest' - restart: unless-stopped \ No newline at end of file + whoogle-search: + image: ${WHOOGLE_IMAGE:-benbusby/whoogle-search} + container_name: whoogle-search + restart: unless-stopped + pids_limit: 50 + mem_limit: 256mb + memswap_limit: 256mb + # user debian-tor from tor package + user: whoogle + security_opt: + - no-new-privileges + cap_drop: + - ALL + tmpfs: + - ${DOCKER_VOLUME_STORAGE:-/mnt/docker-volumes}/whoogle/config/:size=10M,uid=927,gid=927,mode=1700 + - ${DOCKER_VOLUME_STORAGE:-/mnt/docker-volumes}/whoogle/var/lib/tor/:size=15M,uid=927,gid=927,mode=1700 + - ${DOCKER_VOLUME_STORAGE:-/mnt/docker-volumes}/whoogle/run/tor/:size=1M,uid=927,gid=927,mode=1700 + #environment: # Uncomment to configure environment variables + # Basic auth configuration, uncomment to enable + #- WHOOGLE_USER= + #- WHOOGLE_PASS= + # Proxy configuration, uncomment to enable + #- WHOOGLE_PROXY_USER= + #- WHOOGLE_PROXY_PASS= + #- WHOOGLE_PROXY_TYPE= + # Site alternative configurations, uncomment to enable + # Note: If not set, the feature will still be available + # with default values. + #- WHOOGLE_ALT_TW=farside.link/nitter + #- WHOOGLE_ALT_YT=farside.link/invidious + #- WHOOGLE_ALT_IG=farside.link/bibliogram/u + #- WHOOGLE_ALT_RD=farside.link/libreddit + #- WHOOGLE_ALT_MD=farside.link/scribe + #- WHOOGLE_ALT_TL=farside.link/lingva + #- WHOOGLE_ALT_IMG=farside.link/rimgo + #- WHOOGLE_ALT_WIKI=farside.link/wikiless + #- WHOOGLE_ALT_IMDB=farside.link/libremdb + #- WHOOGLE_ALT_QUORA=farside.link/quetre + #env_file: # Alternatively, load variables from whoogle.env + #- whoogle.env + ports: + - 5000:5000 \ No newline at end of file