test: add local 2x2 route topology
This commit is contained in:
@@ -0,0 +1,71 @@
|
||||
services:
|
||||
syncthing:
|
||||
image: syncthing/syncthing:2.1.2@sha256:4464f4161dd0251e20d46bb3aec83363db75d80cef1abdd5d5fd4054b04a004d
|
||||
user: "1001:1001"
|
||||
entrypoint: ["/e2e/start-syncthing.sh"]
|
||||
hostname: syncthing-archive-1
|
||||
volumes:
|
||||
- ../common/start-syncthing.sh:/e2e/start-syncthing.sh:ro
|
||||
- ./secrets:/run/secrets:ro
|
||||
- ./runtime/syncthing:/var/syncthing
|
||||
- ./runtime/sync:/sync
|
||||
networks:
|
||||
archive-control-e2e:
|
||||
aliases: [syncthing-archive-1]
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "curl -fkLsS -m 2 127.0.0.1:8384/rest/noauth/health | grep -q OK"]
|
||||
interval: 2s
|
||||
timeout: 2s
|
||||
retries: 30
|
||||
restart: unless-stopped
|
||||
|
||||
qbittorrent:
|
||||
image: lscr.io/linuxserver/qbittorrent:latest@sha256:b024436f8ca665d16d9a997d26fd27fdf867ee5566ba09f32764e7b2976d3e02
|
||||
environment:
|
||||
PUID: "1001"
|
||||
PGID: "1001"
|
||||
TZ: Etc/UTC
|
||||
WEBUI_PORT: "8080"
|
||||
TORRENTING_PORT: "6881"
|
||||
volumes:
|
||||
- ./runtime/qb-config:/config
|
||||
- ./runtime/qb-data:/downloads
|
||||
networks:
|
||||
archive-control-e2e:
|
||||
aliases: [qb-archive-1]
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "curl -fsS -m 2 http://127.0.0.1:8080/api/v2/app/version >/dev/null"]
|
||||
interval: 2s
|
||||
timeout: 2s
|
||||
retries: 30
|
||||
restart: unless-stopped
|
||||
|
||||
client:
|
||||
image: archive-clients:e2e
|
||||
build:
|
||||
context: ../..
|
||||
dockerfile: Dockerfile
|
||||
user: "1001:1001"
|
||||
command: ["--config", "/etc/archive-control/client.toml"]
|
||||
depends_on:
|
||||
syncthing:
|
||||
condition: service_healthy
|
||||
qbittorrent:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
- ./config/client.toml:/etc/archive-control/client.toml:ro
|
||||
- ./secrets:/run/secrets:ro
|
||||
- ./runtime/client-state:/var/lib/archive-control
|
||||
- ./runtime/client-backups:/var/backups/archive-control
|
||||
- ./runtime/qb-data:/data/qb
|
||||
- ./runtime/sync:/data/sync
|
||||
networks:
|
||||
archive-control-e2e:
|
||||
aliases: [client-archive-1]
|
||||
restart: unless-stopped
|
||||
|
||||
networks:
|
||||
archive-control-e2e:
|
||||
external: true
|
||||
name: archive-control-e2e
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
client_id = "archive-1"
|
||||
display_name = "E2E Archive 1"
|
||||
role = "archive"
|
||||
control_endpoint = "ws://control:8765/archive_control"
|
||||
shared_token_file = "/run/secrets/archive_control_token"
|
||||
state_db = "/var/lib/archive-control/client.db"
|
||||
backup_dir = "/var/backups/archive-control"
|
||||
|
||||
[connection]
|
||||
registration_timeout = "5s"
|
||||
heartbeat_interval = "2s"
|
||||
offline_timeout = "10s"
|
||||
reconnect_initial = "1s"
|
||||
reconnect_max = "5s"
|
||||
reconnect_reset_after = "10s"
|
||||
reconnect_jitter = false
|
||||
|
||||
[qbittorrent]
|
||||
endpoint = "http://qb-archive-1:8080"
|
||||
username = "admin"
|
||||
password_file = "/run/secrets/qb_password"
|
||||
api_root = "/downloads"
|
||||
local_root = "/data/qb"
|
||||
|
||||
[syncthing]
|
||||
endpoint = "http://syncthing-archive-1:8384"
|
||||
api_key_file = "/run/secrets/syncthing_api_key"
|
||||
api_root = "/sync"
|
||||
local_root = "/data/sync"
|
||||
advertised_addresses = ["tcp://syncthing-archive-1:22000"]
|
||||
|
||||
Reference in New Issue
Block a user