aboutsummaryrefslogtreecommitdiffstats
path: root/community/rspamd/conf-split-workers.patch
diff options
context:
space:
mode:
Diffstat (limited to 'community/rspamd/conf-split-workers.patch')
-rw-r--r--community/rspamd/conf-split-workers.patch88
1 files changed, 88 insertions, 0 deletions
diff --git a/community/rspamd/conf-split-workers.patch b/community/rspamd/conf-split-workers.patch
new file mode 100644
index 0000000000..505d2c72e0
--- /dev/null
+++ b/community/rspamd/conf-split-workers.patch
@@ -0,0 +1,88 @@
+Since we split workers into subpackages, we have to split the main config
+that defines workers to be loaded.
+
+NOTE: This is intentionally done in patch file instead of modifying the config
+with sed and generating the worker configs to avoid silent breakages when
+upgrading the aport!
+
+--- a/conf/rspamd.conf
++++ b/conf/rspamd.conf
+@@ -35,33 +35,4 @@
+ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/logging.inc"
+ }
+
+-worker "normal" {
+- bind_socket = "localhost:11333";
+- .include "$CONFDIR/worker-normal.inc"
+- .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-normal.inc"
+- .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-normal.inc"
+-}
+-
+-worker "controller" {
+- bind_socket = "localhost:11334";
+- .include "$CONFDIR/worker-controller.inc"
+- .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-controller.inc"
+- .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-controller.inc"
+-}
+-
+-worker "rspamd_proxy" {
+- bind_socket = "localhost:11332";
+- .include "$CONFDIR/worker-proxy.inc"
+- .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-proxy.inc"
+- .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-proxy.inc"
+-}
+-
+-# Local fuzzy storage is disabled by default
+-
+-worker "fuzzy" {
+- bind_socket = "localhost:11335";
+- count = -1; # Disable by default
+- .include "$CONFDIR/worker-fuzzy.inc"
+- .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-fuzzy.inc"
+- .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-fuzzy.inc"
+-}
++.include(glob=true) "$CONFDIR/worker-*.conf"
+--- /dev/null
++++ b/conf/worker-normal.conf
+@@ -0,0 +1,8 @@
++# Included from top-level .conf file
++
++worker "normal" {
++ bind_socket = "localhost:11333";
++ .include "$CONFDIR/worker-normal.inc"
++ .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-normal.inc"
++ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-normal.inc"
++}
+--- /dev/null
++++ b/conf/worker-controller.conf
+@@ -0,0 +1,8 @@
++# Included from top-level .conf file
++
++worker "controller" {
++ bind_socket = "localhost:11334";
++ .include "$CONFDIR/worker-controller.inc"
++ .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-controller.inc"
++ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-controller.inc"
++}
+--- /dev/null
++++ b/conf/worker-proxy.conf
+@@ -0,0 +1,8 @@
++# Included from top-level .conf file
++
++worker "rspamd_proxy" {
++ bind_socket = "localhost:11332";
++ .include "$CONFDIR/worker-proxy.inc"
++ .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-proxy.inc"
++ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-proxy.inc"
++}
+--- /dev/null
++++ b/conf/worker-fuzzy.conf
+@@ -0,0 +1,8 @@
++# Included from top-level .conf file
++
++worker "fuzzy" {
++ bind_socket = "localhost:11335";
++ .include "$CONFDIR/worker-fuzzy.inc"
++ .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-fuzzy.inc"
++ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-fuzzy.inc"
++}