From c5a562a08b736dc181f9108dcb93eef0ae51c81e Mon Sep 17 00:00:00 2001 From: root Date: Sat, 16 Nov 2024 11:31:00 +0000 Subject: [PATCH] change some settings for torrc and haproxy config --- haproxy/haproxy.cfg | 26 +++++++++++++++++++++++--- tor/docker-compose.yml | 8 ++++++++ tor/torrc | 10 ++++++++-- 3 files changed, 39 insertions(+), 5 deletions(-) diff --git a/haproxy/haproxy.cfg b/haproxy/haproxy.cfg index 17f884f..9c1e023 100644 --- a/haproxy/haproxy.cfg +++ b/haproxy/haproxy.cfg @@ -1,6 +1,26 @@ +global +log stdout format raw local0 debug + +defaults +log global +retries 0 +timeout connect 604800s +timeout client 604800s +timeout server 604800s +timeout tunnel 604800s +timeout queue 604800s +timeout http-request 604800s +timeout http-keep-alive 604800s +timeout client-fin 604800s +timeout server-fin 604800s +timeout check 604800s +option tcplog + frontend tor-north - bind 127.0.0.1:19818 accept-proxy - default_backend inspircd-south + bind 127.0.0.1:19818 accept-proxy + mode tcp + default_backend inspircd-south backend inspircd-south - server inspircd 127.0.0.1:7001 check send-proxy-v2 + mode tcp + server inspircd 127.0.0.1:7001 send-proxy-v2 diff --git a/tor/docker-compose.yml b/tor/docker-compose.yml index 34d9342..e1da7b2 100644 --- a/tor/docker-compose.yml +++ b/tor/docker-compose.yml @@ -7,6 +7,14 @@ services: network_mode: "host" volumes: - data:/var/lib/inspircd + ulimits: + nofile: + soft: "102400" + hard: "102400" + logging: + driver: "json-file" + options: + max-size: "64k" volumes: data: name: tor_data diff --git a/tor/torrc b/tor/torrc index e0dcbec..03850ba 100644 --- a/tor/torrc +++ b/tor/torrc @@ -1,10 +1,16 @@ +DNSPort 0 +SocksPort 0 +TransPort 0 +NATDPort 0 RunAsDaemon 0 DataDirectory /var/lib/tor HiddenServiceDir /var/lib/tor/ircd HiddenServicePort 6667 127.0.0.1:19818 -HiddenServiceMaxStreams 10240 +HiddenServiceMaxStreams 65535 HiddenServiceExportCircuitID haproxy CookieAuthentication 0 ControlPort 127.0.0.1:9051 HardwareAccel 1 -Log notice stderr +Log info stderr +HiddenServiceSingleHopMode 1 +HiddenServiceNonAnonymousMode 1