Commit 03205710 authored by Mike Hibler's avatar Mike Hibler

Grr...spell the sitevariable name correctly!

parent a3f42091
......@@ -31,26 +31,6 @@ my $reportwait = ( 2 * 60);
my $checkwait = 15;
my $maximagesize = (6 * 1024**3); # 20GB
#
# Use defaults from sitevars (if they exist) for some of these.
#
my $tmp;
if (TBGetSiteVar("image/create/maxwait", \$tmp)) {
$maxwait = $tmp * 60;
}
if (TBGetSiteVar("image/create/idlewait", \$tmp)) {
$idlewait = $tmp * 60;
}
if (TBGetSiteVar("image/create/maxsize", \$tmp)) {
$maximagesize = $tmp * 1024**3;
}
$idlewait = $maxwait
if ($maxwait < $idlewait);
$reportwait = $idlewait
if ($idlewait < $reportwait);
$checkwait = $reportwait
if ($reportwait < $checkwait);
#
# Create a disk image.
#
......@@ -174,6 +154,26 @@ if (defined($options{"p"})) {
}
}
#
# Reset default values from site variables if they exist.
#
my $tmp;
if (TBGetSiteVar("images/create/maxwait", \$tmp)) {
$maxwait = $tmp * 60;
}
if (TBGetSiteVar("images/create/idlewait", \$tmp)) {
$idlewait = $tmp * 60;
}
if (TBGetSiteVar("images/create/maxsize", \$tmp)) {
$maximagesize = $tmp * 1024**3;
}
$idlewait = $maxwait
if ($maxwait < $idlewait);
$reportwait = $idlewait
if ($idlewait < $reportwait);
$checkwait = $reportwait
if ($reportwait < $checkwait);
#
# Verify user and get his DB uid and other info for later.
#
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment