file(GLOB_RECURSE CONF_FILES RELATIVE "${CMAKE_SOURCE_DIR}/conf" CONFIGURE_DEPENDS
${GLOB_PATTERNS})
+
+ # Exclude hyperscan-specific config when hyperscan is disabled
+ if (NOT ENABLE_HYPERSCAN)
+ list(REMOVE_ITEM CONF_FILES "worker-hs_helper.conf" "worker-hs_helper.inc")
+ endif ()
+
foreach (CONF_FILE ${CONF_FILES})
get_filename_component(_rp ${CONF_FILE} PATH)
install(CODE "FILE(MAKE_DIRECTORY \$ENV{DESTDIR}${CONFDIR}/${_rp})")
.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"
}
+
+# Hyperscan helper worker (only available when built with hyperscan support)
+.include(try=true) "$CONFDIR/worker-hs_helper.conf"
--- /dev/null
+# Hyperscan helper worker
+# This file is only installed when hyperscan support is enabled
+
+worker "hs_helper" {
+ .include "$CONFDIR/worker-hs_helper.inc"
+ .include(try=true; priority=1,duplicate=merge) "$LOCAL_CONFDIR/local.d/worker-hs_helper.inc"
+ .include(try=true; priority=10) "$LOCAL_CONFDIR/override.d/worker-hs_helper.inc"
+}
--- /dev/null
+# Hyperscan helper worker setup
+# Please don't modify this file as your changes might be overwritten with
+# the next update.
+#
+# You can modify 'local.d/worker-hs_helper.inc' to add and merge
+# parameters defined inside this section
+#
+# You can modify 'override.d/worker-hs_helper.inc' to strictly override all
+# parameters defined inside this section
+#
+# See https://rspamd.com/doc/faq.html#what-are-the-locald-and-overrided-directories
+# for details
+#
+# This worker compiles hyperscan databases in the background, allowing
+# the main rspamd process to start quickly without blocking on compilation.
+
+# Directory to store compiled hyperscan databases
+# cache_dir = "${DBDIR}";
+
+# Cache backend: file (default), redis, http, or lua
+# cache_backend = "file";
+
+# Maximum time allowed for compiling a single expression (seconds)
+# timeout = 1.0;
+
+# Time between periodic recompilation checks (seconds)
+# recompile = 60.0;