automa/filesuite/compose.yaml
m1ngsama 1ef24b3be8 improve: best-practice configs for all projects, CLI UX overhaul
Compose improvements:
- forgejo: add healthcheck (/api/healthz), ROOT_URL + SSH_PORT env, LFS
- tailscale: drop redundant privileged (use cap_add only), use devices
  for /dev/net/tun, mount /lib/modules, reliable healthcheck (tailscale
  status), profiles for opt-in DERP, headscale comment in .env.example
- uptime-kuma: add built-in healthcheck (extra/healthcheck)
- filesuite: add healthchecks for both cloudreve and qbittorrent
- minecraft: add mc-health check (built into itzg image), simplify volumes
- teamspeak: add healthcheck via ServerQuery (nc localhost 10011)
- nextcloud: add healthchecks for all 3 services, depends_on with
  service_healthy conditions so startup order is correct

CLI improvements:
- Fix docker compose detection (was broken with space in arg)
- Use global array for project discovery (no word-splitting bugs)
- Empty selection no longer defaults to "all" (safety)
- Show .env.example comments as hints during interactive configure
- Required fields (empty default) loop until user provides a value
- Disable colors when stdout is not a terminal
- compose() wrapper auto-adds --env-file
- Deduplicate project_exists / project_dir helpers
2026-04-15 10:02:41 +08:00

42 lines
1.2 KiB
YAML

services:
cloudreve:
image: cloudreve/cloudreve:latest
container_name: cloudreve
environment:
TZ: "${TZ:-Asia/Shanghai}"
CR_ENABLE_ARIA2: "${CR_ENABLE_ARIA2:-0}"
volumes:
- ./cloudreve-data:/cloudreve/data
- ${DOWNLOADS_DIR:-./downloads}:/data/downloads
ports:
- "${CLOUDREVE_PORT:-5212}:5212"
healthcheck:
test: ["CMD-SHELL", "curl -fSs http://localhost:5212/ || exit 1"]
interval: 30s
timeout: 5s
retries: 3
start_period: 15s
restart: unless-stopped
qbittorrent:
image: lscr.io/linuxserver/qbittorrent:latest
container_name: qbittorrent
environment:
PUID: "${PUID:-1000}"
PGID: "${PGID:-1000}"
TZ: "${TZ:-Asia/Shanghai}"
WEBUI_PORT: "${QB_WEBUI_PORT:-8090}"
volumes:
- ./qbt-config:/config
- ${DOWNLOADS_DIR:-./downloads}:/downloads
ports:
- "${QB_WEBUI_PORT:-8090}:${QB_WEBUI_PORT:-8090}"
- "${QB_BT_PORT:-44773}:${QB_BT_PORT:-44773}"
- "${QB_BT_PORT:-44773}:${QB_BT_PORT:-44773}/udp"
healthcheck:
test: ["CMD-SHELL", "curl -fSs http://localhost:${QB_WEBUI_PORT:-8090}/ || exit 1"]
interval: 30s
timeout: 5s
retries: 3
start_period: 15s
restart: unless-stopped