]> git.pond.sub.org Git - empserver/commitdiff
scripts: Use mailx rather than mail, and drop bogus -e
authorMarkus Armbruster <armbru@pond.sub.org>
Mon, 25 Jun 2012 05:48:21 +0000 (07:48 +0200)
committerMarkus Armbruster <armbru@pond.sub.org>
Fri, 13 Jul 2012 18:15:33 +0000 (20:15 +0200)
scripts/backup
scripts/savecore

index 20a2a6abbc7609d14e44c416cc287288d9c19660..c6c51f06ffad369fc751053ae8e5a1ff67cc2ba0 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh -e
 # Backup script to be run from pre_update_hook
-# Written by Markus Armbruster, 2005
+# Written by Markus Armbruster, 2005-2012
 # This script is in the public domain.
 
 # Use: edit configuration variables below to taste, then set
@@ -63,7 +63,7 @@ tar czf $arc .
 # user's privileges are carefully limited.
 if [ "$remote_host" ]
 then
-    nohup sh -c "scp -qBp '$arc' '$remote_host:$remote_dir' 2>&1 | mail -e -s 'Empire backup save failed' '$email'" </dev/null >/dev/null 2>&1 &
+    nohup sh -c "scp -qBp '$arc' '$remote_host:$remote_dir' 2>&1 | mailx -s 'Empire backup save failed' '$email'" </dev/null >/dev/null 2>&1 &
 fi
 #
 # A more secure alternative is to replace the scp command by something like
index 8057a07414a029685b1b43d4e619e954630d862c..e2b2ae0feee966f9e44ce0f6bc7b717283f038a0 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh -e
 # Script to save core files, to be run from post_crash_dump_hook
-# Written by Markus Armbruster, 2008-2011
+# Written by Markus Armbruster, 2008-2012
 # This script is in the public domain.
 
 # Use: edit configuration variables below to taste, then set
@@ -37,7 +37,6 @@ privlog=
 
 # Program to send mail
 mailx=mailx
-#mailx=mail
 
 # End of configuration