summaryrefslogtreecommitdiff
path: root/courier-mta-devel/courier-mta.install
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2020-04-17 08:21:43 +0200
committerErich Eckner <git@eckner.net>2020-04-17 08:21:43 +0200
commit3a033677d6d2b9a41211de2b2bcc59b0618618bb (patch)
tree18304b45f70ea7ef3ab6b0228a9adcdaa7cf1877 /courier-mta-devel/courier-mta.install
parent31d787caf2d094852c9e1bd6ec9b3caf2c81d240 (diff)
downloadarchlinuxewe-3a033677d6d2b9a41211de2b2bcc59b0618618bb.tar.xz
courier-mta-devel new
Diffstat (limited to 'courier-mta-devel/courier-mta.install')
-rw-r--r--courier-mta-devel/courier-mta.install38
1 files changed, 38 insertions, 0 deletions
diff --git a/courier-mta-devel/courier-mta.install b/courier-mta-devel/courier-mta.install
new file mode 100644
index 000000000..3782c9b72
--- /dev/null
+++ b/courier-mta-devel/courier-mta.install
@@ -0,0 +1,38 @@
+post_install() {
+ #set up the /var/run directory
+ systemd-tmpfiles --create /usr/lib/tmpfiles.d/courier-mta.conf
+
+ # perform all the tasks required of a standard Courier install
+ echo <<<EOF
+To finish the installation, run:
+$ /usr/lib/courier/sysconftool /etc/courier/*.dist
+$ makealiases
+$ makesmtpaccess
+$ /usr/bin/mkdhparams
+And don't forget to configure an account to receive postmaster mail!
+EOF
+}
+
+pre_upgrade() {
+ # the file courier-imapd.conf is renamed to courier-mta.conf from version 0.77.0-2
+ [ -f /usr/lib/tmpfiles.d/courier-imapd.conf ] && rm -f /usr/lib/tmpfiles.d/courier-imapd.conf
+ [ "${1%%.*}" = "1" ] && [ "${2%%.*}" != "1" ] && echo "Please make sure you have read the guidance on pre-unicode maildir names."
+}
+
+post_upgrade() {
+ echo <<<EOF
+Please run
+$ /usr/lib/courier/sysconftool /etc/courier/*.dist
+EOF
+}
+
+pre_remove() {
+ # there may be many files not part of the original installation that would be useful to save
+ # so save the whole configuration directory rather than try to list all possibilities
+ # in backup().
+ mv -f /etc/courier /etc/courier-$1
+ echo "/etc/courier has been saved as /etc/courier-$1 - you may remove this folder if you wish."
+
+ # clean up temporary storage
+ rm -rf /run/courier /var/spool/courier
+}