You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@vcl.apache.org by jf...@apache.org on 2012/06/18 20:26:07 UTC

svn commit: r1351449 - in /incubator/vcl/trunk/web/.ht-inc: blockallocations.php computers.php genkeys.sh requests.php

Author: jfthomps
Date: Mon Jun 18 18:26:07 2012
New Revision: 1351449

URL: http://svn.apache.org/viewvc?rev=1351449&view=rev
Log:
VCL-463
add ability to deploy images as servers

requests.php: modified viewRequests - do not allow reboot/reinstall when reservation is in the reserved state

VCL-576
Finalizing  for 2.3 release

blockallocations.php: modified getCurrentBlockHTML - use full year for start/end dates

computers.php: modified bulkAddComputer - added 'i' switch to preg_match matching all xcat provisioning modules so xCAT2x will show up in the list

genkeys.sh - modified to not require passphrase to be entered - parse it from secrets.php into a temp file, input from file, then remove temp file

Modified:
    incubator/vcl/trunk/web/.ht-inc/blockallocations.php
    incubator/vcl/trunk/web/.ht-inc/computers.php
    incubator/vcl/trunk/web/.ht-inc/genkeys.sh
    incubator/vcl/trunk/web/.ht-inc/requests.php

Modified: incubator/vcl/trunk/web/.ht-inc/blockallocations.php
URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/.ht-inc/blockallocations.php?rev=1351449&r1=1351448&r2=1351449&view=diff
==============================================================================
--- incubator/vcl/trunk/web/.ht-inc/blockallocations.php (original)
+++ incubator/vcl/trunk/web/.ht-inc/blockallocations.php Mon Jun 18 18:26:07 2012
@@ -1181,8 +1181,8 @@ function getCurrentBlockHTML($listonly=0
 	}
 	foreach($blocks as $id => $request) {
 		if($request['available'] == 'weekly') {
-			$query = "SELECT DATE_FORMAT(start, '%m/%d/%y') AS swdate, "
-			       .        "DATE_FORMAT(end, '%m/%d/%y')AS ewdate, " 
+			$query = "SELECT DATE_FORMAT(start, '%m/%d/%Y') AS swdate, "
+			       .        "DATE_FORMAT(end, '%m/%d/%Y')AS ewdate, " 
 			       .        "days "
 			       . "FROM blockWebDate "
 			       . "WHERE blockRequestid = $id";
@@ -1218,8 +1218,8 @@ function getCurrentBlockHTML($listonly=0
 			}
 		}
 		elseif($request['available'] == 'monthly') {
-			$query = "SELECT DATE_FORMAT(start, '%m/%d/%y') AS smdate, "
-			       .        "DATE_FORMAT(end, '%m/%d/%y')AS emdate, " 
+			$query = "SELECT DATE_FORMAT(start, '%m/%d/%Y') AS smdate, "
+			       .        "DATE_FORMAT(end, '%m/%d/%Y')AS emdate, " 
 			       .        "days AS day, "
 			       .        "weeknum "
 			       . "FROM blockWebDate "
@@ -1249,7 +1249,7 @@ function getCurrentBlockHTML($listonly=0
 			}
 		}
 		elseif($request['available'] == 'list') {
-			$query = "SELECT DATE_FORMAT(start, '%m/%d/%y') AS date, "
+			$query = "SELECT DATE_FORMAT(start, '%m/%d/%Y') AS date, "
 			       .        "days AS `order` "
 			       . "FROM blockWebDate "
 			       . "WHERE blockRequestid = $id "

Modified: incubator/vcl/trunk/web/.ht-inc/computers.php
URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/.ht-inc/computers.php?rev=1351449&r1=1351448&r2=1351449&view=diff
==============================================================================
--- incubator/vcl/trunk/web/.ht-inc/computers.php (original)
+++ incubator/vcl/trunk/web/.ht-inc/computers.php Mon Jun 18 18:26:07 2012
@@ -1750,7 +1750,7 @@ function bulkAddComputer() {
 			if($data['type'] == 'lab')
 				$showprovisioning[$id] = $val['prettyname'];
 		}
-		elseif(preg_match('/^xcat/', $val['name']) || $val['name'] == 'none') {
+		elseif(preg_match('/^xcat/i', $val['name']) || $val['name'] == 'none') {
 			$allowedprovisioning['blade'][] = array('id' => $id, 'name' => $val['prettyname']);
 			if($data['type'] == 'blade')
 				$showprovisioning[$id] = $val['prettyname'];

Modified: incubator/vcl/trunk/web/.ht-inc/genkeys.sh
URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/.ht-inc/genkeys.sh?rev=1351449&r1=1351448&r2=1351449&view=diff
==============================================================================
--- incubator/vcl/trunk/web/.ht-inc/genkeys.sh (original)
+++ incubator/vcl/trunk/web/.ht-inc/genkeys.sh Mon Jun 18 18:26:07 2012
@@ -16,5 +16,7 @@
 # limitations under the License.
 
 
-openssl genrsa -aes256 -out keys.pem 2048
-openssl rsa -pubout -in keys.pem -out pubkey.pem
+cat secrets.php | grep pemkey | awk -F "'" '{print $2}' > tmpkeyfile
+openssl genrsa -aes256 -passout file:tmpkeyfile -out keys.pem 2048
+openssl rsa -passin file:tmpkeyfile -pubout -in keys.pem -out pubkey.pem
+rm -f tmpkeyfile

Modified: incubator/vcl/trunk/web/.ht-inc/requests.php
URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/.ht-inc/requests.php?rev=1351449&r1=1351448&r2=1351449&view=diff
==============================================================================
--- incubator/vcl/trunk/web/.ht-inc/requests.php (original)
+++ incubator/vcl/trunk/web/.ht-inc/requests.php Mon Jun 18 18:26:07 2012
@@ -971,8 +971,11 @@ function viewRequests() {
 					}
 					elseif($requests[$i]['server'] && $requests[$i]['currstateid'] == 24)
 						$text .= getViewRequestHTMLitem('checkpointoptiondisable');*/
-					if(! $cluster &&
+					if($requests[$i]['currstateid'] == 8 ||
+					   (! $cluster &&
 					   $requests[$i]['OSinstalltype'] != 'none' &&
+					   $requests[$i]['currstateid'] != 3 &&
+					   $requests[$i]['laststateid'] != 3 &&
 					   $requests[$i]['currstateid'] != 13 &&
 					   $requests[$i]['laststateid'] != 13 &&
 					   $requests[$i]['currstateid'] != 24 &&
@@ -984,7 +987,7 @@ function viewRequests() {
 					   $requests[$i]['currstateid'] != 28 &&
 						$requests[$i]['laststateid'] != 28 &&
 					   $requests[$i]['currstateid'] != 27 &&
-					   $requests[$i]['laststateid'] != 27) {
+					   $requests[$i]['laststateid'] != 27)) {
 						$cont = addContinuationsEntry('AJrebootRequest', $cdata, SECINDAY);
 						$text .= getViewRequestHTMLitem('rebootoption', $cont);
 						$cont = addContinuationsEntry('AJshowReinstallRequest', $cdata, SECINDAY);