projects
/
BackupPC.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
* On the phase 2 retry pass with rsync, verify the cached checksums
[BackupPC.git]
/
cgi-bin
/
BackupPC_Admin
diff --git
a/cgi-bin/BackupPC_Admin
b/cgi-bin/BackupPC_Admin
index
c99ba4c
..
81b85ad
100755
(executable)
--- a/
cgi-bin/BackupPC_Admin
+++ b/
cgi-bin/BackupPC_Admin
@@
-1,4
+1,4
@@
-#!/bin/perl
-T
+#!/bin/perl
#============================================================= -*-perl-*-w
#
# BackupPC_Admin: Apache/CGI interface for BackupPC.
#============================================================= -*-perl-*-w
#
# BackupPC_Admin: Apache/CGI interface for BackupPC.
@@
-39,7
+39,7
@@
#
#========================================================================
#
#
#========================================================================
#
-# Version 2.1.0
_CVS, released 3 Jul 2003
.
+# Version 2.1.0
beta1, released 9 Apr 2004
.
#
# See http://backuppc.sourceforge.net.
#
#
# See http://backuppc.sourceforge.net.
#
@@
-61,6
+61,7
@@
my %ActionDispatch = (
$Lang->{Start_Incr_Backup} => "StartStopBackup",
$Lang->{Start_Full_Backup} => "StartStopBackup",
$Lang->{Stop_Dequeue_Backup} => "StartStopBackup",
$Lang->{Start_Incr_Backup} => "StartStopBackup",
$Lang->{Start_Full_Backup} => "StartStopBackup",
$Lang->{Stop_Dequeue_Backup} => "StartStopBackup",
+ $Lang->{Stop_Dequeue_Archive} => "StartStopBackup",
"queue" => "Queue",
"view" => "View",
"LOGlist" => "LOGlist",
"queue" => "Queue",
"view" => "View",
"LOGlist" => "LOGlist",
@@
-72,6
+73,13
@@
my %ActionDispatch = (
"hostInfo" => "HostInfo",
"generalInfo" => "GeneralInfo",
"restoreInfo" => "RestoreInfo",
"hostInfo" => "HostInfo",
"generalInfo" => "GeneralInfo",
"restoreInfo" => "RestoreInfo",
+ "archiveInfo" => "ArchiveInfo",
+ $Lang->{Start_Archive} => "Archive",
+ "Archive" => "Archive",
+ "Reload" => "ReloadServer",
+ "startServer" => "StartServer",
+ "Stop" => "StopServer",
+ "adminOpts" => "AdminOptions",
);
#
);
#
@@
-80,6
+88,19
@@
my %ActionDispatch = (
$In{action} ||= "hostInfo" if ( defined($In{host}) );
$In{action} = "generalInfo" if ( !defined($ActionDispatch{$In{action}}) );
my $action = $ActionDispatch{$In{action}};
$In{action} ||= "hostInfo" if ( defined($In{host}) );
$In{action} = "generalInfo" if ( !defined($ActionDispatch{$In{action}}) );
my $action = $ActionDispatch{$In{action}};
+
+#
+# For some reason under mod_perl, the use lib above is unreliable,
+# and sometimes the module below cannot be found. Explicitly push
+# the directory onto INC if it is missing. This is an ugly hack;
+# need to figure out what's really going on...
+#
+my $installDir = '/usr/local/BackupPC/lib';
+push(@INC, $installDir) if ( !grep($_ eq $installDir, @INC) );
+
+#
+# Load the relevant action script and run it
+#
require "BackupPC/CGI/$action.pm"
if ( !defined($BackupPC::CGI::{"${action}::"}) );
$BackupPC::CGI::{"${action}::"}{action}();
require "BackupPC/CGI/$action.pm"
if ( !defined($BackupPC::CGI::{"${action}::"}) );
$BackupPC::CGI::{"${action}::"}{action}();