57 lines
1.4 KiB
YAML
57 lines
1.4 KiB
YAML
name: homelab-searxng
|
|
|
|
services:
|
|
searxng:
|
|
image: ${SEARXNG_IMAGE:-docker.io/searxng/searxng:2026.12.3-44427d4a8}
|
|
container_name: ${SEARXNG_CONTAINER_NAME:-homelab-searxng}
|
|
restart: unless-stopped
|
|
depends_on:
|
|
valkey:
|
|
condition: service_healthy
|
|
env_file:
|
|
- .env
|
|
ports:
|
|
- "${SEARXNG_BIND_IP:-0.0.0.0}:${SEARXNG_HTTP_PORT:-8888}:8080/tcp"
|
|
volumes:
|
|
- ./config:/etc/searxng:ro
|
|
- searxng-cache:/var/cache/searxng
|
|
security_opt:
|
|
- no-new-privileges:true
|
|
mem_limit: 768m
|
|
pids_limit: 256
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8080/healthz', timeout=3)"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 5
|
|
start_period: 30s
|
|
networks:
|
|
- searxng
|
|
|
|
valkey:
|
|
image: ${VALKEY_IMAGE:-docker.io/valkey/valkey:9-alpine}
|
|
container_name: ${VALKEY_CONTAINER_NAME:-homelab-searxng-valkey}
|
|
restart: unless-stopped
|
|
command: valkey-server --save 300 1 --save 60 1000 --loglevel warning
|
|
volumes:
|
|
- searxng-valkey:/data
|
|
security_opt:
|
|
- no-new-privileges:true
|
|
mem_limit: 128m
|
|
pids_limit: 64
|
|
healthcheck:
|
|
test: ["CMD", "valkey-cli", "ping"]
|
|
interval: 15s
|
|
timeout: 3s
|
|
retries: 5
|
|
networks:
|
|
- searxng
|
|
|
|
networks:
|
|
searxng:
|
|
name: homelab-searxng
|
|
|
|
volumes:
|
|
searxng-cache:
|
|
searxng-valkey:
|