{
  "minVersion": "0.16.0",
  "services": {
    "tor-exit-relay": {
      "image": "r3bo0tbx1/onion-relay:latest",
      "container_name": "tor-exit-relay",
      "restart": "unless-stopped",
      "network_mode": "host",
      "environment": [
        "TOR_RELAY_MODE=exit",
        "TOR_NICKNAME=MyExitRelay",
        "TOR_CONTACT_INFO=email:admin[]example.com ciissversion:2",
        "TOR_ORPORT=9001",
        "TOR_DIRPORT=0",
        "TOR_BANDWIDTH_RATE=50 MBytes",
        "TOR_BANDWIDTH_BURST=100 MBytes",
        "TOR_EXIT_POLICY=accept *:80,accept *:443,reject *:*"
      ],
      "volumes": [
        {
          "type": "volume",
          "source": "tor-exit-data",
          "target": "/var/lib/tor"
        },
        {
          "type": "volume",
          "source": "tor-exit-logs",
          "target": "/var/log/tor"
        }
      ],
      "security_opt": [
        "no-new-privileges:true"
      ],
      "cap_drop": [
        "ALL"
      ],
      "cap_add": [
        "NET_BIND_SERVICE",
        "CHOWN",
        "SETUID",
        "SETGID",
        "DAC_OVERRIDE"
      ],
      "healthcheck": {
        "test": [
          "CMD-SHELL",
          "/usr/local/bin/healthcheck.sh"
        ],
        "interval": "10m",
        "timeout": "15s",
        "start_period": "30s",
        "retries": 3
      },
      "labels": {
        "cosmos-stack": "TorExitRelay",
        "cosmos-stack-main": "tor-exit-relay",
        "cosmos-description": "⚠️ Tor Exit Relay | ENV-based config",
        "cosmos-icon": "https://raw.githubusercontent.com/r3bo0tbx1/tor-guard-relay/refs/heads/main/src/exit.png",
        "cosmos-auto-update": "true",
        "cosmos-force-network-secured": "false",
        "cosmos-version": "1.1.7"
      }
    }
  },
  "volumes": {
    "tor-exit-data": {},
    "tor-exit-logs": {}
  }
}