ctf-ad-mirror-tool-rust/mirror.example.toml

74 lines
2.0 KiB
TOML

# Copy to mirror.toml. Change web.password before using on a shared network.
# Bind the panel to a VPN interface or put it behind HTTPS when used remotely.
# Optional: own team's checker status in the top strip, as in the legacy UI.
# main_team_ip = "192.0.2.10"
[web]
listen = "0.0.0.0:6700"
password = "mirror-tool-change-me"
password_env = "MIRROR_PASSWORD"
state_file = "data/state.json"
session_ttl_seconds = 43200
secure_cookie = false # true behind HTTPS
[network]
connect_timeout_ms = 2000
buffer_size = 65536
replica_queue_chunks = 16
max_buffered_bytes = 268435456 # global shared payload budget for all replica queues
max_connections = 2048
drain_timeout_ms = 15000
[monitoring]
interval_ms = 3000
timeout_ms = 1000
failure_threshold = 2
recovery_threshold = 2
cooldown_ms = 30000
concurrency = 32
# Optional. ForcAD uses a persistent Engine.IO v4 connection; adplatf uses /state.
# [scoreboard]
# kind = "forcad"
# url = "http://scoreboard.example:8080"
# poll_interval_ms = 3000
# stale_after_ms = 15000
[[teams]]
id = "team-a"
name = "Team A"
address = "192.0.2.10"
[[teams]]
id = "team-b"
name = "Team B"
address = "192.0.2.11"
[[services]]
id = "notes"
name = "Notes"
listen = "0.0.0.0:18080"
upstream_port = 8080
primary = "team-a"
replicas = ["team-b"]
enabled = false
auto_switch = false
# isolate: primary stays fast; explicitly disconnect a slow/failed replica.
# strict: backpressure to deliver all bytes to each healthy replica.
replica_policy = "isolate"
# Optional flag tokenization: disabled for every service unless explicitly enabled.
# Configure a persistent key in MIRROR_FLAG_KEY before uncommenting this section.
# Then set flag_protection = true in a service or enable it in the UI.
# See docs/flag-protection.md for protocol/TTL limitations.
# [flags]
# database = "data/flags.sqlite3"
# key_env = "MIRROR_FLAG_KEY"
# prefix = ""
# alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
# payload_length = 31
# suffix = "="
# ttl_seconds = 86400
# max_entries = 10000
# partial_timeout_ms = 5000