summaryrefslogtreecommitdiff
path: root/etc/relayd.conf
diff options
context:
space:
mode:
authorReyk Floeter <reyk@cvs.openbsd.org>2007-02-26 13:58:32 +0000
committerReyk Floeter <reyk@cvs.openbsd.org>2007-02-26 13:58:32 +0000
commit8555e15060c1d4091d4b3b6f330471caa95c51f5 (patch)
treeedd0d8f1d1417d8f41fe998370b2e6bda17a47c1 /etc/relayd.conf
parented6e6614f3fb6770c09fba3473fb6fb39c63439c (diff)
add an relay example
ok pyr@
Diffstat (limited to 'etc/relayd.conf')
-rw-r--r--etc/relayd.conf28
1 files changed, 27 insertions, 1 deletions
diff --git a/etc/relayd.conf b/etc/relayd.conf
index 52eb13b942c..21cad067177 100644
--- a/etc/relayd.conf
+++ b/etc/relayd.conf
@@ -1,4 +1,4 @@
-# $OpenBSD: relayd.conf,v 1.3 2007/02/26 13:04:34 pyr Exp $
+# $OpenBSD: relayd.conf,v 1.4 2007/02/26 13:58:31 reyk Exp $
#
# Macros
#
@@ -10,6 +10,7 @@ webhost2="10.0.0.2"
#
# interval 10
# timeout 200
+# prefork 5
#
# Each table will be mapped to a pf table.
@@ -39,3 +40,28 @@ service www {
table webhosts
backup table fallback
}
+
+#
+# Relays and protocols are used for Layer 7 loadbalancing
+#
+protocol httpssl {
+ protocol http
+ append "$REMOTE_ADDR" to "X-Forwarded-For"
+ append "$SERVER_ADDR:$SERVER_PORT" to "X-Forwarded-By"
+ change "Connection" to "close"
+
+ # Various TCP performance options
+ tcp { nodelay, sack, socket buffer 65536, backlog 128 }
+
+# ssl { no sslv2, sslv3, tlsv1, ciphers HIGH }
+# ssl session cache disable
+}
+
+relay wwwssl {
+ # Run as a SSL accelerator
+ listen on 192.168.1.1 port 443 ssl
+ protocol httpssl
+
+ # Forward to hosts in the webhosts table using a src/dst hash
+ table webhosts loadbalance
+}