mail/rspamd: add history rows (#1587)

This commit is contained in:
Michael
2019-11-29 18:54:07 +01:00
committed by Franco Fichtner
parent 48c9c27faa
commit 8dc2d35b36
6 changed files with 27 additions and 2 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
PLUGIN_NAME= rspamd
PLUGIN_VERSION= 1.8
PLUGIN_VERSION= 1.9
PLUGIN_COMMENT= Protect your network from spam
PLUGIN_DEPENDS= rspamd
PLUGIN_MAINTAINER= franz.fabian.94@gmail.com
+4
View File
@@ -5,6 +5,10 @@ lua.
Plugin Changelog
----------------
1.9
* Add History Rows field
1.8
* Add Bayes autolearn option
@@ -55,6 +55,13 @@
<advanced>true</advanced>
<help>Enter a prefix added to the subject when Subject Score is reached.</help>
</field>
<field>
<id>rspamd.general.historyrows</id>
<label>History Rows</label>
<type>text</type>
<advanced>true</advanced>
<help>Set the number of rows to be displayed in rspamd UI.</help>
</field>
</subtab>
<subtab id="rspamd-general-multimap" description="Multimap Settings">
<field>
@@ -1,7 +1,7 @@
<model>
<mount>//OPNsense/Rspamd</mount>
<description>rspamd anti spam filter</description>
<version>1.0.0</version>
<version>1.0.1</version>
<items>
<general>
<enabled type="BooleanField">
@@ -119,6 +119,13 @@
<rewritesubject type="TextField">
<Required>N</Required>
</rewritesubject>
<historyrows type="IntegerField">
<default>200</default>
<Required>Y</Required>
<MinimumValue>1</MinimumValue>
<MaximumValue>100000</MaximumValue>
<ValidationMessage>Choose a value between 1 and 100000.</ValidationMessage>
</historyrows>
</general>
<milter_headers>
@@ -20,3 +20,4 @@ ratelimit.conf:/usr/local/etc/rspamd/local.d/ratelimit.conf
redis.conf:/usr/local/etc/rspamd/local.d/redis.conf
spamtrap-map:/usr/local/etc/rspamd/maps.d/spamtrap.map
classifier-bayes.conf:/usr/local/etc/rspamd/local.d/classifier-bayes.conf
history_redis.conf:/usr/local/etc/rspamd/local.d/history_redis.conf
@@ -0,0 +1,6 @@
# Please don't modify this file as your changes might be overwritten with
# the next update.
#
{% if helpers.exists('OPNsense.Rspamd.general.enabled') and OPNsense.Rspamd.general.enabled == '1' %}
nrows = {{ OPNsense.Rspamd.general.historyrows }};
{% endif %}