initial commit of file from CVS for smeserver-qmail-notify on Sat Sep 7 20:57:46 AEST 2024

This commit is contained in:
Trevor Batley 2024-09-07 20:57:46 +10:00
parent 0cbc0c2ab7
commit 6815a080d0
10 changed files with 156 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-qmail-notify
# $Id: Makefile,v 1.1 2021/04/09 22:29:44 jcrisp Exp $
NAME := smeserver-qmail-notify
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-qmail-notify
# <img src="https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png" width="25%" vertical="auto" style="vertical-align:bottom"> smeserver-qmail-notify
SMEServer Koozali developed git repo for smeserver-qmail-notify smecontribs
## Wiki
<br />https://wiki.koozali.org/Qmail-notify
## Bugzilla
Show list of outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=smeserver-qmail-notify&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 />

1
contriborbase Normal file
View File

@ -0,0 +1 @@
contribs10

11
createlinks Executable file
View File

@ -0,0 +1,11 @@
#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
foreach $file (
qw( /etc/crontab ))
{
templates2events($file, qw(bootstrap-console-save email-update smeserver-qmail-notify-update));
}
exit 0

View File

@ -0,0 +1 @@
enabled

View File

@ -0,0 +1 @@
configuration

View File

@ -0,0 +1,19 @@
{
use strict;
use warnings;
use esmith::ConfigDB;
my $configDB = esmith::ConfigDB->open_ro or die("can't open Config DB");
my $dbKey = 'qmail-notify';
my $status = $configDB->get_prop( $dbKey, 'status' ) || 'disabled';
my $minutes = $configDB->get_prop( $dbKey, 'minutes' ) || '30';
my $hours = $configDB->get_prop( $dbKey, 'hours' ) || '*';
my $file = $configDB->get_prop( $dbKey, 'filename' ) || 'qmail-notify-message.txt';
if ( $status eq 'enabled' ) {
$OUT .= "# run qmail-notify\n";
$OUT .= "$minutes $hours * * * root /usr/bin/qmail-notify -r -f /usr/local/lib/qmail-notify/$file\n";
$OUT .= "\n";
}
}

View File

@ -0,0 +1,5 @@
Your message has been received by %s but has been
undeliverable to the following recipients for at least %s.
The mail system will continue to attempt to deliver your message
to these recipients for a total of %s. You do not need to
resend your message at this time.

View File

@ -0,0 +1,79 @@
Summary: notify senders about email that has been held in the qmail queue
%define name smeserver-qmail-notify
Name: %{name}
%define version 2.0.0
%define release 5
Version: %{version}
Release: %{release}
License: GPLv2+
Group: Networking/Info
Source: %{name}-%{version}.tar.xz
Packager: Peter Schubert <psc@s-a-c-o.de>
URL: http://www.saco-support.de/SME
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
BuildArchitectures: noarch
BuildRequires: e-smith-devtools
Requires: e-smith-base
Requires: e-smith-lib
Requires: perl
Requires: qmail-notify
AutoReqProv: no
%description
This package provides templates for a program to notify senders
about email that has been held in the qmail queue
%changelog
* Sat Sep 07 2024 cvs2git.sh aka Brian Read <brianr@koozali.org> 2.0.0-5.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.
* Mon Sep 27 2021 Brian Read <brianr@bjsystems.co.uk> 2.0.0-4.sme
- Fix up createlinks to create update event [SME: 11542 ]
* Mon Sep 27 2021 John Crisp <jcrisp@safeandsoundit.co.uk> 2.0.0-3.sme
- Fix timing in cron template - Zsolt Vasarhelyi [SME: 11542]
* Thu Sep 23 2021 John Crisp <jcrisp@safeandsoundit.co.uk> 2.0.0-2.sme
- Fix typo in cron template - Zsolt Vasarhelyi [SME:11542]
* Fri Apr 09 2021 John Crisp <jcrisp@safeandsoundit.co.uk> 2.0.0-1.sme
- First Import to SME Contribs [SME: 11542]
- Template crontab
- DB configuration enabled, hours, nminutes, alt filename
* Thu Aug 29 2002 Peter Schubert <psc@s-a-c-o.de> 1.0.0-01
- First release
%prep
%setup
%build
perl createlinks
rm -rf $RPM_BUILD_ROOT
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
rm -f e-smith-%{version}-filelist
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist
%clean
rm -rf $RPM_BUILD_ROOT
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)
%pre
%post
/sbin/e-smith/expand-template /etc/crontab
%preun
%postun