flamethrower (0.1.8-3) direct (non packaging) changes

Summary

 HOWTO                          |    3 ++-
 README                         |    4 ++--
 bin/flamethrower               |   17 +++++++++++------
 bin/flamethrowerd              |    4 ++--
 etc/flamethrower.conf          |    7 ++++++-
 etc/init.d/flamethrower-server |    9 ++++-----
 6 files changed, 27 insertions(+), 17 deletions(-)

    
download this patch

Patch contents

--- flamethrower-0.1.8.orig/HOWTO
+++ flamethrower-0.1.8/HOWTO
@@ -2,7 +2,8 @@
 in the SystemImager manual.  A stand-alone "Flamethrower HOWTO" will be along
 shortly.
 
-You can find the Official SystemImager manual here: http://www.systemimager.org/
+You can find the Official SystemImager manual at: http://www.systemimager.org,
+or in the systemimager-doc package.
 
 Cheers, -Brian
 
--- flamethrower-0.1.8.orig/README
+++ flamethrower-0.1.8/README
@@ -3,7 +3,7 @@
 #
 #   Copyright (C) 2003 Brian Elliott Finley <finley@mcs.anl.gov>
 #
-#   $Id: README 32 2003-07-01 03:54:42Z dannf $
+#   $Id: README 60 2006-04-18 23:07:43Z dannf $
 #
 
 What it is:
@@ -16,7 +16,7 @@
 
 Notable characteristics:
 
-    1)  Works with entire directory heirarchies of files, not just single files.
+    1)  Works with entire directory hierarchies of files, not just single files.
     2)  Uses a server configuration file that takes module entries that are 
         similar to those used by rsyncd.conf.
 
--- flamethrower-0.1.8.orig/etc/flamethrower.conf
+++ flamethrower-0.1.8/etc/flamethrower.conf
@@ -1,9 +1,14 @@
+###############################################################################
+### IF YOU ARE TRYING TO CONFIGURE FLAMETHROWER FOR USE WITH SYSTEMIMAGER   ###
+### YOU ARE LOOKING AT THE WRONG FILE - USE THE CONFIG IN /etc/systemimager ###
+###############################################################################
+
 #
 #   "Flamethrower"
 #
 #   Copyright (C) 2003 Bald Guy Software <brian@bgsw.net>
 #
-#   $Id: flamethrower.conf 56 2006-01-24 02:08:52Z bli $
+#   $Id: flamethrower.conf 59 2006-04-18 23:05:44Z dannf $
 #
 #   NOTE:  For additional details on many of these settings, see 
 #          "man udp-sender".
--- flamethrower-0.1.8.orig/etc/init.d/flamethrower-server
+++ flamethrower-0.1.8/etc/init.d/flamethrower-server
@@ -16,13 +16,12 @@
 # Support for LSB compliant init system:
 ### BEGIN INIT INFO
 # Provides: flamethrowerd
-# Required-Start: $network $syslog
-# Required-Stop:
-# Default-Start:  3 5
-# Default-Stop:   0 1 2 6
+# Required-Start: $remote_fs $syslog $network
+# Required-Stop:  $remote_fs $syslog
+# Default-Start:  2 3 4 5
+# Default-Stop:   0 1 6
 # Short-Description: Daemon for multicast file distribution
 # Description: Daemon for multicast file distribution
-#
 ### END INIT INFO
 
 kill_em_all() {
--- flamethrower-0.1.8.orig/bin/flamethrower
+++ flamethrower-0.1.8/bin/flamethrower
@@ -9,6 +9,7 @@
 
 use strict;
 use File::Path;
+use File::Temp;
 use Getopt::Long;
 
 use lib "/usr/lib/flamethrower";
@@ -23,7 +24,7 @@
 my $version_number  = "INS_VERSION";
 my $conf_file       = '/etc/flamethrower/flamethrower.conf';
 my $transport       = "udp-receiver";
-my $tmp_dir         = "/tmp/.flamethrower.$$";
+my $tmp_dir         = File::Temp::tempdir();
 
 
 my $version_info = <<"EOF";
@@ -283,13 +284,16 @@
     #
     my $udp_cmd;
     my $tar_cmd;
+    my $tar_fh;
+    my $tar_file;
 
+    ($tar_fh, $tar_file) = File::Temp::tempfile();
     if($verbose) {
-        $udp_cmd = "udp-receiver $udp_receiver_options --file /tmp/multicast.tar.$$";
-        $tar_cmd = "tar $tar_opts -C $dir -f /tmp/multicast.tar.$$";
+        $udp_cmd = "udp-receiver $udp_receiver_options --file $tar_file";
+        $tar_cmd = "tar $tar_opts -C $dir -f $tar_file";
     } else {
-        $udp_cmd = "udp-receiver $udp_receiver_options --file /tmp/multicast.tar.$$ 2>/dev/null";
-        $tar_cmd = "tar $tar_opts -C $dir -f /tmp/multicast.tar.$$";
+        $udp_cmd = "udp-receiver $udp_receiver_options --file $tar_file 2>/dev/null";
+        $tar_cmd = "tar $tar_opts -C $dir -f $tar_file";
     }
 
     print "$udp_cmd\n" if($verbose);
@@ -298,7 +302,8 @@
     print "$tar_cmd\n" if($verbose);
     !system($tar_cmd) or die("FAILED: $tar_cmd");
 
-    unlink("/tmp/multicast.tar.$$");
+    close $tar_fh;
+    unlink("$tar_file");
 }
 
 
--- flamethrower-0.1.8.orig/bin/flamethrowerd
+++ flamethrower-0.1.8/bin/flamethrowerd
@@ -5,7 +5,7 @@
 #   Copyright (C) 2003 Bald Guy Software 
 #                      Brian Elliott Finley <brian@bgsw.net>
 #
-#   $Id: flamethrowerd 45 2003-11-17 00:12:55Z brianfinley $
+#   $Id: flamethrowerd 59 2006-04-18 23:05:44Z dannf $
 #
 
 $0 = "flamethrowerd";
@@ -343,7 +343,7 @@
     # Create our directory directory, if necessary.
     my $dir = $ft_config->get("flamethrower_directory_dir");
     if ( ! -e $dir ) {
-        mkdir("$dir", 0755) or die("Couddn't mkdir $dir!");
+        mkdir("$dir", 0755) or die("Couldn't mkdir $dir!");
     }
     unlink <$dir/*>;