initial commit of file from CVS for smeserver-altqmail on Sat Sep 7 20:06:59 AEST 2024

This commit is contained in:
Trevor Batley 2024-09-07 20:06:59 +10:00
parent c535ecdbab
commit 8a31f1fcf2
31 changed files with 901 additions and 2 deletions

4
.gitignore vendored Normal file
View File

@ -0,0 +1,4 @@
*.rpm
*.log
*spec-20*
*.tar.gz

21
Makefile Normal file
View File

@ -0,0 +1,21 @@
# Makefile for source rpm: smeserver-altqmail
# $Id: Makefile,v 1.1 2023/03/23 03:10:20 jpp Exp $
NAME := smeserver-altqmail
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)

View File

@ -1,3 +1,15 @@
# smeserver-altqmail # <img src="https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png" width="25%" vertical="auto" style="vertical-align:bottom"> smeserver-altqmail
SMEServer Koozali developed git repo for smeserver-altqmail smecontribs SMEServer Koozali developed git repo for smeserver-altqmail smecontribs
## Wiki
<br />https://wiki.koozali.org/AltQmail
## Bugzilla
Show list of outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=smeserver-altqmail&product=SME%20Contribs&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED)
## Description
<br />*This description has been generated by an LLM AI system and cannot be relied on to be fully correct.*
*Once it has been checked, then this comment will be deleted*
<br />

View File

@ -0,0 +1,3 @@
the .tito/packages directory contains metadata files
named after their packages. Each file has the latest tagged
version and the project's relative directory.

View File

@ -0,0 +1 @@
0.1.2-1 ./

View File

@ -0,0 +1 @@
../../tito_libs/releasers.conf

View File

@ -0,0 +1,6 @@
[buildconfig]
builder = tito.builder.Builder
tagger = tito.tagger.VersionTagger
changelog_do_not_remove_cherrypick = 0
changelog_format = %s (%ae)
lib_dir = ../tito_libs

View File

@ -0,0 +1,220 @@
Summary: Second qmail instance
Name: smeserver-altqmail
Version: 0.1.2
Release: 1%{?dist}
License: GPL
Group: Networking/Daemons
Source: %{name}-%{version}.tar.gz
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
BuildArchitectures: noarch
BuildRequires: e-smith-devtools
Requires: e-smith-base >= 5.2.0
Requires: qmail
%description
Provides a second qmail instance, with its own configuration
Usefull if you want to reduce the ConcurrencyRemote option
only for some domains
%changelog
* Sun Nov 19 2017 Daniel Berteaud <daniel@firewall-services.com> 0.1.2-1
- Fixes in spec file (daniel@firewall-services.com)
- Add tito's global lib_dir (daniel@firewall-services.com)
* Sun Nov 19 2017 Daniel Berteaud <daniel@firewall-services.com> 0.1.1-1
- new package built with tito
* Wed Dec 3 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.1-1.sme
- Works on x86_64 and SME9
* Fri Sep 19 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-3.sme
- Yet another permission fix on remote/19 and local/19
* Mon May 19 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-2.sme
- Fix permissions on info/19 subdir
* Wed May 7 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-1.sme
- Initial release
%prep
%setup -q -n %{name}-%{version}
%build
%{__mkdir_p} root/var/log/{altqmail,altqmail-smtpd}
perl createlinks
mkdir -p root/var/service/altqmail/root/var/qmail/{queue,control,bin}
# Create the chrooted qmail queue
pushd root/var/service/altqmail/root/var/qmail/queue
mkdir pid
mkdir mess
mkdir todo
mkdir bounce
for i in `seq 0 22`; do
mkdir -p mess/$i
done
cp -r mess info
cp -r mess intd
cp -r mess local
cp -r mess remote
mkdir lock
dd bs=1024 count=1 if=/dev/zero of=lock/tcpto
mkfifo lock/trigger
touch lock/sendmutex
popd
%install
/bin/rm -rf $RPM_BUILD_ROOT
(cd root ; /usr/bin/find . -depth -print | /bin/cpio -dump $RPM_BUILD_ROOT)
/bin/rm -f %{name}-%{version}-filelist
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
--file /var/service/altqmail/run 'attr(0755,root,root)' \
--file /var/service/altqmail/finish 'attr(0755,root,root)' \
--file /var/service/altqmail/log/run 'attr(0755,root,root)' \
--file /var/service/altqmail-smtpd/run 'attr(0755,root,root)' \
--file /var/service/altqmail-smtpd/log/run 'attr(0755,root,root)' \
--dir /var/log/altqmail 'attr(0750,qmaill,root)' \
--dir /var/log/altqmail-smtpd 'attr(0750,qmaill,root)' \
--dir /var/service/altqmail/root/var/qmail/queue 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/bounce 'attr(0755,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/lock 'attr(0750,qmailq,qmail)' \
--file /var/service/altqmail/root/var/qmail/queue/lock/tcpto 'attr(0644,qmailr,qmail)' \
--file /var/service/altqmail/root/var/qmail/queue/lock/sendmutex 'attr(0600,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/0 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/1 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/2 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/3 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/4 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/5 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/6 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/7 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/8 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/9 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/10 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/11 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/12 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/13 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/14 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/15 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/16 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/17 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/18 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/19 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/20 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/21 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/22 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/pid 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/0 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/1 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/2 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/3 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/4 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/5 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/6 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/7 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/8 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/9 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/10 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/11 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/12 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/13 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/14 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/15 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/16 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/17 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/18 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/19 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/20 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/21 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/22 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/todo 'attr(0750,qmailq,qmail)' \
> %{name}-%{version}-filelist
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)
%clean
rm -rf $RPM_BUILD_ROOT
%pre
%post
%preun

1
contriborbase Normal file
View File

@ -0,0 +1 @@
contribs10

56
createlinks Normal file
View File

@ -0,0 +1,56 @@
#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
#service_link_enhanced("altqmail", "S80", "7");
#service_link_enhanced("altqmail", "K60", "6");
#service_link_enhanced("altqmail", "K60", "0");
#service_link_enhanced("altqmail", "K60", "1");
#service_link_enhanced("altqmail-smtpd", "S80", "7");
#service_link_enhanced("altqmail-smtpd", "K60", "6");
#service_link_enhanced("altqmail-smtpd", "K60", "0");
#service_link_enhanced("altqmail-smtpd", "K60", "1");
safe_touch("root/var/service/altqmail/down");
safe_touch("root/var/service/altqmail-smtpd/down");
#safe_symlink("../daemontools" , 'root/etc/rc.d/init.d/supervise/altqmail');
#safe_symlink("../daemontools" , 'root/etc/rc.d/init.d/supervise/altqmail-smtpd');
safe_symlink("/var/service/altqmail" , 'root/service/altqmail');
safe_symlink("/var/service/altqmail-smtpd" , 'root/service/altqmail-smtpd');
safe_symlink("reload-or-restart", "root/etc/e-smith/events/email-update/services2adjust/altqmail");
safe_symlink("reload-or-restart", "root/etc/e-smith/events/email-update/services2adjust/altqmail-smtpd");
foreach my $f (qw(me bouncehost smtproutes concurrencyremote outratelimit)){
safe_touch("root/etc/e-smith/templates/var/service/altqmail/root/var/qmail/control/$f/template-begin");
templates2events("/var/service/altqmail/root/var/qmail/control/$f", qw(email-update bootstrap-console-save));
}
my $pkg= "smeserver-altqmail";
my $event = "${pkg}-update";
event_actions($event, qw(
systemd-default 88
systemd-reload 89
));
event_templates($event, qw(
/var/service/altqmail/root/var/qmail/control/me
/var/service/altqmail/root/var/qmail/control/bouncehost
/var/service/altqmail/root/var/qmail/control/smtproutes
/var/service/altqmail/root/var/qmail/control/concurrencyremote
/var/service/altqmail/root/var/qmail/control/outratelimit
));
event_services($event, qw(
altqmail reload-or-restart
altqmail-smtpd reload-or-restart
qmail restart
));
#nothing to backup restore
#use esmith::Build::Backup qw(:all);
#backup_includes($pkg, qw(
#/opt/foo/
#));

View File

@ -0,0 +1 @@
localhost

View File

@ -0,0 +1 @@
enabled

View File

@ -0,0 +1 @@
service

View File

@ -0,0 +1 @@
enabled

View File

@ -0,0 +1 @@
service

View File

@ -0,0 +1,9 @@
{
$OUT = '';
foreach my $domain (split /[,;]/, ($altqmail{'Domains'} || '')){
$OUT .= "$domain:127.0.0.1:" . (${'altqmail-smtpd'}{'TCPPort'} || '27') . "\n";
}
}

View File

@ -0,0 +1 @@
{ $DB->get('altqmail')->prop('ConcurrencyRemote') || "5"; }

View File

@ -0,0 +1 @@
altqmail.{$DomainName}

View File

@ -0,0 +1 @@
{ $DB->get('altqmail')->prop('OutRateLimit') || "20/3600"; }

View File

@ -0,0 +1,18 @@
{
$OUT = '';
use esmith::DomainsDB;
my $domainsdb = esmith::DomainsDB->open_ro();
for my $domain ($domainsdb->domains)
{
my $mail_server = $domain->prop('MailServer')
|| $DelegateMailServer
|| 'localhost';
next if ( $mail_server ne 'localhost' );
$emaildomain = $domain->key;
$OUT .= "$emaildomain:127.0.0.1\n";
}
}

View File

@ -0,0 +1,16 @@
[Unit]
Description=altqmail-smtpd, message transfer agent
After=network.target
Requires=runit.service
[Service]
Type=oneshot
ExecStartPre=/sbin/e-smith/service-status altqmail-smtpd
ExecStart=/usr/bin/sv u /service/altqmail-smtpd
ExecStop=/usr/bin/sv stop /service/altqmail-smtpd
ExecReload=/usr/bin/sv t /service/altqmail-smtpd
RemainAfterExit=yes
[Install]
WantedBy=sme-server.target

View File

@ -0,0 +1,16 @@
[Unit]
Description=altqmail, message transfer agent
After=network.target
Requires=runit.service
[Service]
Type=oneshot
ExecStartPre=/sbin/e-smith/service-status altqmail
ExecStart=/usr/bin/sv u /service/altqmail
ExecStop=/usr/bin/sv stop /service/altqmail
ExecReload=/usr/bin/sv t /service/altqmail
RemainAfterExit=yes
[Install]
WantedBy=sme-server.target

View File

@ -0,0 +1,9 @@
#!/bin/sh
NUM=$(/sbin/e-smith/db configuration getprop altqmail-smtpd KeepLogFiles)
exec \
/usr/local/bin/setuidgid qmaill \
/usr/local/bin/multilog t s5000000 \
n${NUM:-10} \
/var/log/altqmail-smtpd

View File

@ -0,0 +1,9 @@
#!/bin/sh
PORT=$(/sbin/e-smith/db configuration getprop altqmail-smtpd TCPPort)
exec \
/usr/bin/env - PATH="/var/qmail/bin:/bin:/usr/bin:/usr/local/bin" \
tcpsvd -vv 127.0.0.1 ${PORT:-27} \
chpst -u qmails -/ ../altqmail/root /var/qmail/bin/qmail-smtpd \
2>&1

View File

@ -0,0 +1,6 @@
#!/bin/sh
#umount /var/service/altqmail/root/var/qmail/bin
rm -rf /var/service/altqmail/root/var/qmail/bin/*
rm -rf root/etc
rm -rf root/lib{,64}

View File

@ -0,0 +1,9 @@
#!/bin/sh
NUM=$(/sbin/e-smith/db configuration getprop altqmail KeepLogFiles)
exec \
/usr/local/bin/setuidgid qmaill \
/usr/local/bin/multilog t s5000000 \
n${NUM:-10} \
/var/log/altqmail

View File

@ -0,0 +1,119 @@
#!/usr/bin/perl
use Fcntl ':flock';
$QMAIL = "/var/qmail";
$CONTROL = "$QMAIL/control";
open LOG, ">>", "/tmp/qmail-remote-log";
{ my $ofh = select LOG; $|=1; select $ofh; }
Log("starting");
$msgs = 0;
$time = 0;
load_policy();
while(1) {
my @last = grep {$_ > time() - $time} read_log();
Log("status " . @last . "/$msgs");
if (@last >= $msgs) {
# Log("sleeping");
} else {
last;
}
while (@last >= $msgs) {
my $oldest = $last[0];
my $age = time() - $oldest;
# When will the oldest message expire off the queue?
# The end of the queue is $time seconds ago
# The age of the oldest message is now time() - $oldest
# The oldest message will expire in $time - $age seconds
my $zzz = $time - $age + int(rand(3));
$zzz = 1 if $zzz < 1;
# Log("Sleeping for $zzz secs");
sleep $zzz;
shift @last while @last && $last[0] < time() - $time;
load_policy();
}
}
append_log(time());
#if (open F, ">>", "/tmp/qmail-remote-log") {
# print F time(), " @ARGV\n";
#}
Log("sending @ARGV");
exec "/var/qmail/bin/qmail-remote.real", @ARGV;
exit 0;
sub fail {
my $msg = shift;
Log("fail: $msg");
print "Z$msg";
exit 0;
}
my $last_policy_load ;
sub load_policy {
my $POLICY = "$CONTROL/outratelimit";
return if ((stat($POLICY))[9] <= $last_policy_load);
if (open F, "<", $POLICY) {
chomp(my $line = <F>);
($msgs, $time) = split m{/}, $line;
if (defined $last_policy_load) {
Log("Policy changed to $msgs/$time");
}
$last_policy_load = time();
close F;
}
}
sub read_log {
lock_semaphore(LOCK_SH);
my @last;
if (open(F, "+<", "$CONTROL/outlog")) {
chomp(@last = <F>);
close F;
}
lock_semaphore(LOCK_UN);
return @last;
}
sub append_log {
lock_semaphore(LOCK_EX);
if (open(F, "+<", "$CONTROL/outlog")) {
my @last = grep {$_ > time() - $time} <F>;
chomp(@last);
truncate F, 0;
seek F, 0, 0;
print F join "\n", @last, @_, "";
close F;
}
lock_semaphore(LOCK_UN);
}
sub lock_semaphore {
if (open SEM, ">", "$CONTROL/qmail-remote-semaphore") {
flock(SEM, $_[0]) or fail("Couldn't lock semaphore: $!");
} else {
fail("Couldn't open semaphore: $!");
}
}
sub Log {
my @args = @_;
tr/\n//d for @args;
print LOG time(), " $$ @args\n";
}

View File

@ -0,0 +1,110 @@
#! /bin/sh
exec 2>&1
#/bin/mount --bind /var/qmail/bin/ root/var/qmail/bin
if [ ! -f root/var/qmail/bin/ ]; then
cp -a /var/qmail/bin/* root/var/qmail/bin/
mv root/var/qmail/bin/qmail-remote root/var/qmail/bin/qmail-remote.real
cp -a qmail-remote-throttle root/var/qmail/bin/qmail-remote
fi
if [ ! -d root/etc ]; then
mkdir root/etc
cp -a /etc/resolv.conf root/etc
cp -a /etc/services root/etc
cp -a /etc/passwd root/etc
cp -a /etc/group root/etc
fi
LIBDIR="lib"
LIBC="2.17"
if [ -d /lib64 ]; then
LIBDIR="lib64"
fi
if [ ! -d root/$LIBDIR ]; then
mkdir root/$LIBDIR
cp -a /$LIBDIR/libc-$LIBC.so root/$LIBDIR
ln -s libc-$LIBC.so root/$LIBDIR/libc.so.6
cp -a /$LIBDIR/ld-$LIBC.so root/$LIBDIR
if [ -d /lib64 ]; then
ln -s ld-$LIBC.so root/$LIBDIR/ld-linux-x86-64.so.2
else
ln -s ld-$LIBC.so root/$LIBDIR/ld-linux.so.2
fi
cp -a /$LIBDIR/libnss_files-$LIBC.so root/$LIBDIR
ln -s libnss_files-$LIBC.so root/$LIBDIR/libnss_files.so.2
cp -a /$LIBDIR/libresolv-$LIBC.so root/$LIBDIR
ln -s libresolv-$LIBC.so root/$LIBDIR/libresolv.so.2
## added for throttle
# for perl /usr/bin/perl
#cp --parents `ldd BIN_PATH | cut -d " " -f 3` CHROOT_PATH
#cp -a --parents `ldd /usr/bin/perl | cut -d " " -f 3` root/
# wold almost work inside a loop checking if link and cpying also the target
cp -a --parents /usr/$LIBDIR/perl5/CORE/libperl.so root/
cp -a --parents /$LIBDIR/libresolv.so.2 root/
cp -a --parents /$LIBDIR/libnsl.so.1 root/
cp -a --parents /$LIBDIR/libnsl-$LIBC.so root/
cp -a --parents /$LIBDIR/libdl.so.2 root/
cp -a --parents /$LIBDIR/libdl-$LIBC.so root/
cp -a --parents /$LIBDIR/libm.so.6 root/
cp -a --parents /$LIBDIR/libm-$LIBC.so root/
cp -a --parents /$LIBDIR/libcrypt.so.1 root/
cp -a --parents /$LIBDIR/libcrypt-$LIBC.so root/
cp -a --parents /$LIBDIR/libutil.so.1 root/
cp -a --parents /$LIBDIR/libutil-$LIBC.so root/
cp -a --parents /$LIBDIR/libpthread.so.0 root/
cp -a --parents /$LIBDIR/libpthread-$LIBC.so root/
cp -a --parents /lib64/libfreebl3.so root/
cp -a --parents /usr/$LIBDIR/perl5/Fcntl.pm root/
cp -a --parents /usr/$LIBDIR/perl5/auto/Fcntl root/
cp -a --parents /usr/share/perl5/strict.pm root/
cp -a --parents /usr/share/perl5/AutoLoader.pm root/
cp -a --parents /usr/share/perl5/Carp.pm root/
cp -a --parents /usr/share/perl5/Carp/Heavy.pm root/
cp -a --parents /usr/share/perl5/Exporter.pm root/
cp -a --parents /usr/share/perl5/Exporter root/
cp -a --parents /usr/share/perl5/warnings.pm root/
cp -a --parents /usr/$LIBDIR/perl5/XSLoader.pm root/
cp -a --parents /usr/$LIBDIR/perl5/DynaLoader.pm root/
cp -a --parents /usr/$LIBDIR/perl5/Config.pm root/
cp -a --parents /usr/$LIBDIR/perl5/Config_heavy.pl root/
cp -a --parents /usr/$LIBDIR/perl5/Config_git.pl root/
cp -a --parents /usr/$LIBDIR/perl5/auto/DynaLoader/dl_findfile.al root/
# might better somewhere else
cp -a --parents /usr/bin/perl root/
# this one is needed to set locale for perl
cp -a --parent /usr/lib/locale root/
#bin sh for qmail-qstat
cp -a --parents /bin/sh root/
cp -a --parents /bin/bash root/
cp -a --parents /$LIBDIR/libtinfo.so.5 root/
cp -a --parents /$LIBDIR/libtinfo.so.5.7 root/
cp -a --parents /usr/bin/wc root/
cp -a --parents /bin/find root/
cp -a --parents /usr/bin/expr root/
cp -a --parents /$LIBDIR/libselinux.so.1 root/
cp -a --parents /$LIBDIR/librt.so.1 root/
cp -a --parents /$LIBDIR/librt-2.12.so root/
cp -a --parents /usr/$LIBDIR/libgmp.so.3 root/
cp -a --parents /usr/$LIBDIR/libgmp.so.3.5.0 root/
fi
chown qmails:qmail root/var/qmail/queue/lock/trigger
chmod 622 root/var/qmail/queue/lock/trigger
exec \
/usr/bin/env - PATH="/var/qmail/bin:/bin:/usr/bin:/usr/local/bin" \
/usr/sbin/chroot root /var/qmail/bin/qmail-start \
./Maildir/

243
smeserver-altqmail.spec Normal file
View File

@ -0,0 +1,243 @@
Summary: Second qmail instance
Name: smeserver-altqmail
Version: 0.1.2
Release: 3%{?dist}
License: GPL
Group: Networking/Daemons
Source: %{name}-%{version}.tar.xz
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
BuildArchitectures: noarch
BuildRequires: e-smith-devtools
Requires: e-smith-base >= 5.2.0
Requires: qmail
%description
Provides a second qmail instance, with its own configuration
Usefull if you want to reduce the ConcurrencyRemote option
only for some domains
%changelog
* Sat Sep 07 2024 cvs2git.sh aka Brian Read <brianr@koozali.org> 0.1.2-3.sme
- Roll up patches and move to git repo [SME: 12338]
* Sat Sep 07 2024 BogusDateBot
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday,
by assuming the date is correct and changing the weekday.
* Thu Mar 23 2023 Jean-Philippe Pialasse <tests@pialasse.com> 0.1.2-2.sme
- import to SME10 [SME: 12344]
adapt for systemd and add update event
add throttle capability
* Sun Nov 19 2017 Daniel Berteaud <daniel@firewall-services.com> 0.1.2-1
- Fixes in spec file (daniel@firewall-services.com)
- Add tito's global lib_dir (daniel@firewall-services.com)
* Sun Nov 19 2017 Daniel Berteaud <daniel@firewall-services.com> 0.1.1-1
- new package built with tito
* Wed Dec 3 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.1-1.sme
- Works on x86_64 and SME9
* Fri Sep 19 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-3.sme
- Yet another permission fix on remote/19 and local/19
* Mon May 19 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-2.sme
- Fix permissions on info/19 subdir
* Wed May 7 2014 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-1.sme
- Initial release
%prep
%setup -q -n %{name}-%{version}
%build
%{__mkdir_p} root/var/log/{altqmail,altqmail-smtpd}
perl createlinks
mkdir -p root/var/service/altqmail/root/var/qmail/{queue,control,bin}
mkdir -p root/var/service/altqmail/root/tmp
mkdir -p root/var/service/altqmail/root/var/qmail/control/
echo "20/3600" > root/var/service/altqmail/root/var/qmail/control/outratelimit
touch root/var/service/altqmail/root/var/qmail/control/qmail-remote-semaphore
touch root/var/service/altqmail/root/var/qmail/control/outlog
# Create the chrooted qmail queue
pushd root/var/service/altqmail/root/var/qmail/queue
mkdir pid
mkdir mess
mkdir todo
mkdir bounce
for i in `seq 0 22`; do
mkdir -p mess/$i
done
cp -r mess info
cp -r mess intd
cp -r mess local
cp -r mess remote
mkdir lock
dd bs=1024 count=1 if=/dev/zero of=lock/tcpto
mkfifo lock/trigger
touch lock/sendmutex
popd
%install
/bin/rm -rf $RPM_BUILD_ROOT
(cd root ; /usr/bin/find . -depth -print | /bin/cpio -dump $RPM_BUILD_ROOT)
/bin/rm -f %{name}-%{version}-filelist
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
--file /var/service/altqmail/run 'attr(0755,root,root)' \
--file /var/service/altqmail/finish 'attr(0755,root,root)' \
--file /var/service/altqmail/log/run 'attr(0755,root,root)' \
--file /var/service/altqmail-smtpd/run 'attr(0755,root,root)' \
--file /var/service/altqmail/qmail-remote-throttle 'attr(0755,root,qmail)' \
--file /var/service/altqmail-smtpd/log/run 'attr(0755,root,root)' \
--dir /var/log/altqmail 'attr(0750,qmaill,root)' \
--dir /var/log/altqmail-smtpd 'attr(0750,qmaill,root)' \
--dir /var/service/altqmail/root/tmp 'attr(0777,root,root)' \
--file /var/service/altqmail/root/var/qmail/control/outratelimit 'attr(0644,root,root)' \
--file /var/service/altqmail/root/var/qmail/control/qmail-remote-semaphore 'attr(0554,root,qmail)' \
--file /var/service/altqmail/root/var/qmail/control/outlog 'attr(0554,root,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/bounce 'attr(0755,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/lock 'attr(0750,qmailq,qmail)' \
--file /var/service/altqmail/root/var/qmail/queue/lock/tcpto 'attr(0644,qmailr,qmail)' \
--file /var/service/altqmail/root/var/qmail/queue/lock/sendmutex 'attr(0600,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/0 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/1 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/2 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/3 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/4 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/5 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/6 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/7 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/8 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/9 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/10 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/11 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/12 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/13 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/14 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/15 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/16 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/17 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/18 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/19 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/20 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/21 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/intd/22 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/local/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/info/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/pid 'attr(0700,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/0 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/1 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/2 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/3 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/4 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/5 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/6 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/7 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/8 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/9 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/10 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/11 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/12 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/13 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/14 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/15 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/16 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/17 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/18 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/19 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/20 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/21 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/remote/22 'attr(0700,qmails,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/0 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/1 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/2 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/3 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/4 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/5 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/6 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/7 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/8 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/9 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/10 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/11 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/12 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/13 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/14 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/15 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/16 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/17 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/18 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/19 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/20 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/21 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/mess/22 'attr(0750,qmailq,qmail)' \
--dir /var/service/altqmail/root/var/qmail/queue/todo 'attr(0750,qmailq,qmail)' \
> %{name}-%{version}-filelist
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)
%clean
rm -rf $RPM_BUILD_ROOT
%pre
%post
%preun