Changeset 35594 for branches/eam_branches/ipp-20130509/pstamp
- Timestamp:
- May 24, 2013, 1:37:30 PM (13 years ago)
- Location:
- branches/eam_branches/ipp-20130509
- Files:
-
- 4 edited
-
. (modified) (1 prop)
-
pstamp/scripts (modified) (1 prop)
-
pstamp/scripts/pstamp_save_server_status.pl (modified) (2 diffs)
-
pstamp/test/maketestreq (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20130509
- Property svn:mergeinfo changed
/trunk (added) merged: 35566-35570,35572-35574,35576-35581,35583-35586,35590
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20130509/pstamp/scripts
- Property svn:mergeinfo changed
/trunk/pstamp/scripts (added) merged: 35569-35570
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20130509/pstamp/scripts/pstamp_save_server_status.pl
r30469 r35594 12 12 use Pod::Usage qw( pod2usage ); 13 13 14 # XXX: We should get this from site.config, but that would about double15 # the execution time for this script.16 my $rundir = "/data/ippc17.0/pstamp";17 18 my $status_file = "$rundir/web/status.html";19 20 14 my $updatelink; 21 15 my $verbose; 22 16 my $save_temps; 17 my $pstamp_workdir; 23 18 24 19 GetOptions( 25 ' rundir=s' => \$rundir,20 'workdir=s' => \$pstamp_workdir, 26 21 'update-link' => \$updatelink, 27 22 'verbose' => \$verbose, … … 37 32 } 38 33 34 if (!$pstamp_workdir) { 35 my $ipprc = PS::IPP::Config->new(); # IPP Configuration 36 $pstamp_workdir = metadataLookupStr($ipprc->{_siteConfig}, 'PSTAMP_WORKDIR'); 37 } 38 39 if (!$pstamp_workdir) { 40 warn("Failed to find PSTAMP_WORKDIR in the config\n"); 41 exit($PS_EXIT_CONFIG_ERROR); 42 } 43 my $status_file = "$pstamp_workdir/server_status/status.html"; 44 39 45 my ($sec, $min, $hour, $mday, $month, $year) = gmtime; 40 46 $year += 1900; 41 47 $month += 1; 42 48 43 my $dir = sprintf "$ rundir/work/server_status/%4d/%02d/%02d", $year, $month, $mday;49 my $dir = sprintf "$pstamp_workdir/server_status/%4d/%02d/%02d", $year, $month, $mday; 44 50 45 51 if (!-e $dir ) { -
branches/eam_branches/ipp-20130509/pstamp/test/maketestreq
r35441 r35594 30 30 } 31 31 32 # XXX: get these from site.config33 $pstamptool .= " -dbserver ippc19 -dbname ippRequestServer";34 35 32 36 33 my ($input, $submit, $listfile, $delete, $simple, $tag_req_name, $req_name, $email); 34 my ($dbname, $dbserver); 37 35 my ($save_temps, $verbose); 38 36 … … 50 48 'label=s' => \$label, 51 49 'email=s' => \$email, 50 51 'dbname=s' => \$dbname, 52 'dbserver=s' => \$dbserver, 52 53 53 54 'listfile|l' => \$listfile, … … 68 69 die ("Input file $input not found\n") unless (-e $input); 69 70 die ("Input file $input not readable\n") unless (-r $input); 71 72 if (!$dbname or !$dbserver) { 73 my $ipprc = PS::IPP::Config->new('GPC1'); 74 75 if (!$dbserver) { 76 $dbserver = metadataLookupStr($ipprc->{_siteConfig}, 'PS_DBSERVER'); 77 die ("couldn't find dbserver in site.config\n") unless $dbserver; 78 } 79 if (!$dbname) { 80 $dbname = metadataLookupStr($ipprc->{_siteConfig}, 'PS_DBNAME'); 81 die ("couldn't find dbname in site.config\n") unless $dbname; 82 } 83 } 84 $pstamptool .= " -dbserver $dbserver -dbname $dbname"; 85 70 86 71 87 # if request name was not supplied make one
Note:
See TracChangeset
for help on using the changeset viewer.
