summaryrefslogtreecommitdiffstats
path: root/config-db
diff options
context:
space:
mode:
authorOliver Tappe2006-09-29 19:28:15 +0200
committerOliver Tappe2006-09-29 19:28:15 +0200
commitf8131908b0f36e8546117b9ccf3ffe96e350d7f8 (patch)
treeb57dca4e21d7f05e71cb2a0b2cabf789245b2bba /config-db
parent* added 'export-path' (which defaults to '/srv/openslx/export'). (diff)
downloadcore-f8131908b0f36e8546117b9ccf3ffe96e350d7f8.tar.gz
core-f8131908b0f36e8546117b9ccf3ffe96e350d7f8.tar.xz
core-f8131908b0f36e8546117b9ccf3ffe96e350d7f8.zip
* some cleanup and clearifications
* changed 'client-conf'-path to 'client-config', as 'config' is what we use in other places. * changed name of generated initalramfs-file from 'initialramfs' to 'initramfs' as that is the phrase used in other places. git-svn-id: http://svn.openslx.org/svn/openslx/trunk@414 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'config-db')
-rwxr-xr-xconfig-db/slxconfig-demuxer.pl30
1 files changed, 15 insertions, 15 deletions
diff --git a/config-db/slxconfig-demuxer.pl b/config-db/slxconfig-demuxer.pl
index a454d61b..6ac7be75 100755
--- a/config-db/slxconfig-demuxer.pl
+++ b/config-db/slxconfig-demuxer.pl
@@ -53,22 +53,22 @@ if (!$dryRun) {
die _tr("Unable to create or access temp-path '%s'!", $tempPath);
}
}
-my $exportPath = "$openslxConfig{'public-path'}/tftpboot";
+my $tftpbootPath = $openslxConfig{'tftpboot-path'};
if (!$dryRun) {
- system("rm -rf $exportPath/client-conf/* $exportPath/pxe/*");
- system("mkdir -p $exportPath/client-conf $exportPath/pxe/pxelinux.cfg");
- if (!-d $exportPath) {
- die _tr("Unable to create or access export-path '%s'!", $exportPath);
+ system("rm -rf $tftpbootPath/client-config/* $tftpbootPath/pxe/*");
+ system("mkdir -p $tftpbootPath/client-config $tftpbootPath/pxe/pxelinux.cfg");
+ if (!-d $tftpbootPath) {
+ die _tr("Unable to create or access tftpboot-path '%s'!", $tftpbootPath);
}
}
-my $lockFile = "$exportPath/config-demuxer.lock";
+my $lockFile = "$tftpbootPath/config-demuxer.lock";
lockScript($lockFile);
writeConfigurations();
my $wr = ($dryRun ? "would have written" : "wrote");
-print "$wr $systemConfCount systems and $clientSystemConfCount client-configurations to $exportPath/client-conf\n";
+print "$wr $systemConfCount systems and $clientSystemConfCount client-configurations to $tftpbootPath/client-config\n";
disconnectConfigDB($openslxDB);
@@ -175,8 +175,8 @@ sub createTarOfPath
################################################################################
sub writePXEMenus
{
- my $pxePath = "$exportPath/pxe";
- my $pxeConfigPath = "$exportPath/pxe/pxelinux.cfg";
+ my $pxePath = "$tftpbootPath/pxe";
+ my $pxeConfigPath = "$tftpbootPath/pxe/pxelinux.cfg";
if (!-e "$pxePath/pxelinux.0") {
my $pxelinux0Path
@@ -204,7 +204,7 @@ sub writePXEMenus
foreach my $info (@infos) {
my $extSysID = externalIDForSystem($info);
my $append = $system->{kernel_params};
- $append .= " initrd=$extSysID/initialramfs";
+ $append .= " initrd=$extSysID/initramfs";
$append .= " $clientAppend";
$append .= " rootfs=$info->{'export-uri'} file";
print PXE "LABEL openslx-$extSysID\n";
@@ -225,7 +225,7 @@ sub generateInitalRamFS
my $vendorOS = shift;
my $pxeSysPath = shift;
- vlog 1, _tr('generating initialramfs %s/initialramfs', $pxeSysPath);
+ vlog 1, _tr('generating initialramfs %s/initramfs', $pxeSysPath);
my $cmd = "$openslxConfig{'bin-path'}/slxmkramfs ";
if ($setup->{ramfs_use_glibc}) {
$cmd .= '-g ';
@@ -245,7 +245,7 @@ sub generateInitalRamFS
}
my $rootPath
= "$openslxConfig{'private-path'}/stage1/$vendorOS->{path}";
- $cmd .= "-i $pxeSysPath/initialramfs -r $rootPath";
+ $cmd .= "-i $pxeSysPath/initramfs -r $rootPath";
$ENV{'SLX_PRIVATE_PATH'} = $openslxConfig{'private-path'};
$ENV{'SLX_PUBLIC_PATH'} = $openslxConfig{'public-path'};
@@ -258,7 +258,7 @@ sub writeSystemPXEFiles
{
my $system = shift;
- my $pxePath = "$exportPath/pxe";
+ my $pxePath = "$tftpbootPath/pxe";
my $vendorOS = fetchVendorOSesByID($openslxDB, $system->{vendor_os_id});
my @infos = aggregatedSystemFileInfosOfSystem($openslxDB, $system);
@@ -300,7 +300,7 @@ sub writeClientConfigurationsForSystem
my $externalClientID = externalIDForClient($client);
my $externalSystemID = externalIDForSystem($system);
createTarOfPath($buildPath, "${externalClientID}.tgz",
- "$exportPath/client-conf/$externalSystemID");
+ "$tftpbootPath/client-config/$externalSystemID");
}
}
@@ -321,7 +321,7 @@ sub writeSystemConfigurations
writeAttributesToFile($system, $attrFile);
my $externalSystemID = externalIDForSystem($system);
- my $systemPath = "$exportPath/client-conf/$externalSystemID";
+ my $systemPath = "$tftpbootPath/client-config/$externalSystemID";
createTarOfPath($buildPath, "default.tgz", $systemPath);
writeSystemPXEFiles($system);