Rebase razor homedir/logfile patch.
This commit is contained in:
parent
611550bb6e
commit
5d7ea08ffb
@ -1,43 +0,0 @@
|
|||||||
commit bb177c93c8852417fc5a522cbcc45abbab4b3c3d
|
|
||||||
Author: Tomas Korbar <tomas.korb@seznam.cz>
|
|
||||||
Date: Thu Jun 7 20:57:07 2018 +0200
|
|
||||||
|
|
||||||
Add razor log path and home directory option
|
|
||||||
|
|
||||||
diff --git a/lib/Mail/SpamAssassin/Plugin/Razor2.pm b/lib/Mail/SpamAssassin/Plugin/Razor2.pm
|
|
||||||
index e24252c..935b3ac 100644
|
|
||||||
--- a/lib/Mail/SpamAssassin/Plugin/Razor2.pm
|
|
||||||
+++ b/lib/Mail/SpamAssassin/Plugin/Razor2.pm
|
|
||||||
@@ -165,7 +165,9 @@ sub razor2_access {
|
|
||||||
$rc->{opt} = {
|
|
||||||
debug => (would_log('dbg', $debug) > 1),
|
|
||||||
foreground => 1,
|
|
||||||
- config => $self->{main}->{conf}->{razor_config}
|
|
||||||
+ config => $self->{main}->{conf}->{razor_config},
|
|
||||||
+ logfile => $self->{main}->{razor_log_file},
|
|
||||||
+ razorhome => $self->{main}->{razor_home_dir}
|
|
||||||
};
|
|
||||||
# no facility prefix on this die
|
|
||||||
$rc->do_conf() or die "$debug: " . $rc->errstr;
|
|
||||||
diff --git a/spamd/spamd.raw b/spamd/spamd.raw
|
|
||||||
index 821f658..2afd6bb 100755
|
|
||||||
--- a/spamd/spamd.raw
|
|
||||||
+++ b/spamd/spamd.raw
|
|
||||||
@@ -361,6 +361,8 @@ prepare_for_sighup_restart();
|
|
||||||
# Parse the command line
|
|
||||||
Getopt::Long::Configure("bundling");
|
|
||||||
GetOptions(
|
|
||||||
+ 'razor-home-dir=s' => \$opt{'razor_home_dir'},
|
|
||||||
+ 'razor-log-file=s' => \$opt{'razor_log_file'},
|
|
||||||
'allow-tell' => \$opt{'tell'},
|
|
||||||
'allowed-ips|A=s' => \@{ $opt{'allowed-ip'} },
|
|
||||||
'auth-ident' => \$opt{'auth-ident'},
|
|
||||||
@@ -1149,6 +1151,8 @@ if ( defined $opt{'pidfile'} ) {
|
|
||||||
|
|
||||||
my $spamtest = Mail::SpamAssassin->new(
|
|
||||||
{
|
|
||||||
+ razor_home_dir => $opt{'razor_home_dir'},
|
|
||||||
+ razor_log_file => $opt{'razor_log_file'},
|
|
||||||
dont_copy_prefs => $dontcopy,
|
|
||||||
rules_filename => ( $opt{'configpath'} || 0 ),
|
|
||||||
site_rules_filename => ( $opt{'siteconfigpath'} || 0 ),
|
|
35
spamassassin-4.0.0-add-logfile-homedir-options.patch
Normal file
35
spamassassin-4.0.0-add-logfile-homedir-options.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
diff --color -Nur Mail-SpamAssassin-4.0.0.orig/lib/Mail/SpamAssassin/Plugin/Razor2.pm Mail-SpamAssassin-4.0.0/lib/Mail/SpamAssassin/Plugin/Razor2.pm
|
||||||
|
--- Mail-SpamAssassin-4.0.0.orig/lib/Mail/SpamAssassin/Plugin/Razor2.pm 2022-12-13 22:03:20.000000000 -0800
|
||||||
|
+++ Mail-SpamAssassin-4.0.0/lib/Mail/SpamAssassin/Plugin/Razor2.pm 2022-12-21 12:14:41.978518595 -0800
|
||||||
|
@@ -185,7 +185,9 @@
|
||||||
|
$rc->{opt} = {
|
||||||
|
debug => (would_log('dbg', $debug) > 1),
|
||||||
|
foreground => 1,
|
||||||
|
- config => $self->{main}->{conf}->{razor_config}
|
||||||
|
+ config => $self->{main}->{conf}->{razor_config},
|
||||||
|
+ logfile => $self->{main}->{razor_log_file},
|
||||||
|
+ razorhome => $self->{main}->{razor_home_dir}
|
||||||
|
};
|
||||||
|
# no facility prefix on this die
|
||||||
|
$rc->do_conf() or die "$debug: " . $rc->errstr;
|
||||||
|
diff --color -Nur Mail-SpamAssassin-4.0.0.orig/spamd/spamd.raw Mail-SpamAssassin-4.0.0/spamd/spamd.raw
|
||||||
|
--- Mail-SpamAssassin-4.0.0.orig/spamd/spamd.raw 2022-12-13 22:03:27.000000000 -0800
|
||||||
|
+++ Mail-SpamAssassin-4.0.0/spamd/spamd.raw 2022-12-21 12:13:38.426637129 -0800
|
||||||
|
@@ -378,6 +378,8 @@
|
||||||
|
# Parse the command line
|
||||||
|
Getopt::Long::Configure("bundling");
|
||||||
|
GetOptions(
|
||||||
|
+ 'razor-home-dir=s' => \$opt{'razor_home_dir'},
|
||||||
|
+ 'razor-log-file=s' => \$opt{'razor_log_file'},
|
||||||
|
'allow-tell' => \$opt{'tell'},
|
||||||
|
'allowed-ips|A=s' => \@{ $opt{'allowed-ip'} },
|
||||||
|
'configpath|C=s' => \$opt{'configpath'},
|
||||||
|
@@ -1195,6 +1197,8 @@
|
||||||
|
|
||||||
|
my $spamtest = Mail::SpamAssassin->new(
|
||||||
|
{
|
||||||
|
+ razor_home_dir => ( $opt{'razor_home_dir'} || 0),
|
||||||
|
+ razor_log_file => ( $opt{'razor_log_file'} || 0),
|
||||||
|
dont_copy_prefs => $dontcopy,
|
||||||
|
rules_filename => ( $opt{'configpath'} || 0 ),
|
||||||
|
site_rules_filename => ( $opt{'siteconfigpath'} || 0 ),
|
@ -60,7 +60,7 @@ Summary: Spam filter for email which can be invoked from mail delivery agents
|
|||||||
Name: spamassassin
|
Name: spamassassin
|
||||||
Version: 4.0.0
|
Version: 4.0.0
|
||||||
#Release: 0.8.%%{prerev}%%{?dist}
|
#Release: 0.8.%%{prerev}%%{?dist}
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: https://spamassassin.apache.org/
|
URL: https://spamassassin.apache.org/
|
||||||
Source0: https://www.apache.org/dist/%{name}/source/%{real_name}-%{version}.tar.bz2
|
Source0: https://www.apache.org/dist/%{name}/source/%{real_name}-%{version}.tar.bz2
|
||||||
@ -89,7 +89,8 @@ Source17: sa-update.timer
|
|||||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1055593
|
# https://bugzilla.redhat.com/show_bug.cgi?id=1055593
|
||||||
# Switch to using gnupg2 instead of gnupg1
|
# Switch to using gnupg2 instead of gnupg1
|
||||||
Patch0: spamassassin-4.0.0-gnupg2.patch
|
Patch0: spamassassin-4.0.0-gnupg2.patch
|
||||||
Patch1: spamassassin-3.4.1-add-logfile-homedir-options.patch
|
# add a logfile and homedir for razor
|
||||||
|
Patch1: spamassassin-4.0.0-add-logfile-homedir-options.patch
|
||||||
# end of patches
|
# end of patches
|
||||||
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
||||||
%if %{use_systemd} == 0
|
%if %{use_systemd} == 0
|
||||||
@ -208,6 +209,7 @@ To filter spam for all users, add that line to /etc/procmailrc
|
|||||||
%setup -q -n Mail-SpamAssassin-%{version}
|
%setup -q -n Mail-SpamAssassin-%{version}
|
||||||
# Patches 0-99 are RH specific
|
# Patches 0-99 are RH specific
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
|
%patch1 -p1
|
||||||
# end of patches
|
# end of patches
|
||||||
|
|
||||||
echo "RHEL=%{?rhel} FEDORA=%{?fedora}"
|
echo "RHEL=%{?rhel} FEDORA=%{?fedora}"
|
||||||
@ -388,6 +390,9 @@ exit 0
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Dec 21 2022 Kevin Fenzi <kevin@scrye.com> - 4.0.0-2
|
||||||
|
- Rebase razor homedir/logfile patch.
|
||||||
|
|
||||||
* Sat Dec 17 2022 Kevin Fenzi <kevin@scrye.com> - 4.0.0-1
|
* Sat Dec 17 2022 Kevin Fenzi <kevin@scrye.com> - 4.0.0-1
|
||||||
- Update to 4.0.0. Fixes rhbz#2154501
|
- Update to 4.0.0. Fixes rhbz#2154501
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user