summaryrefslogtreecommitdiffstats
path: root/installer
diff options
context:
space:
mode:
authorOliver Tappe2007-06-17 12:29:17 +0200
committerOliver Tappe2007-06-17 12:29:17 +0200
commit9ba85d5dc63dfd1e16b9ec85d532fe89ee58fd9b (patch)
tree176dc068777af9af1119c55648ec73e78517393e /installer
parentEnabled busybox option to allow longer filenames in tar archives (see (diff)
downloadcore-9ba85d5dc63dfd1e16b9ec85d532fe89ee58fd9b.tar.gz
core-9ba85d5dc63dfd1e16b9ec85d532fe89ee58fd9b.tar.xz
core-9ba85d5dc63dfd1e16b9ec85d532fe89ee58fd9b.zip
largish change with respect to configurable paths:
* instead of supporting configurable paths at different hierarchy levels, there are now only five configurable folder: + base-path (/opt/openslx), fixed at installation time + config-path (/etc/opt/openslx), fixed at installation time + private-path (/var/opt/openslx), freely configurable by user + public-path (/srv/openslx), freely configurable by user + temp-path (/tmp), freely configurable by user this closes ticket#143 * several holes have been plugged concerning the creation of folders before they are accessed, closing ticket#142 * the functionality of generating config default folders has been moved from the Makefile into a new Perl-module (ConfigFolder.pm), in order to be available to the Perl-scripts, too * slxsettings has been changed to reflect the nature of base-path and config-path as fixed paths git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1172 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'installer')
-rw-r--r--installer/OpenSLX/OSExport/Engine.pm6
-rw-r--r--installer/OpenSLX/OSExport/ExportType/NBD_Squash.pm2
-rw-r--r--installer/OpenSLX/OSExport/ExportType/NFS.pm3
-rw-r--r--installer/OpenSLX/OSSetup/Distro/Base.pm2
-rw-r--r--installer/OpenSLX/OSSetup/Engine.pm12
-rw-r--r--installer/default_files/hwdata/Cards.local2
-rw-r--r--installer/default_files/hwdata/pcitable.local2
-rwxr-xr-xinstaller/slxos-export13
-rwxr-xr-xinstaller/slxos-setup11
9 files changed, 18 insertions, 35 deletions
diff --git a/installer/OpenSLX/OSExport/Engine.pm b/installer/OpenSLX/OSExport/Engine.pm
index d02ac597..6668416a 100644
--- a/installer/OpenSLX/OSExport/Engine.pm
+++ b/installer/OpenSLX/OSExport/Engine.pm
@@ -208,9 +208,9 @@ sub _initialize
# setup source and target paths:
$self->{'vendor-os-path'}
- = "$openslxConfig{'stage1-path'}/$vendorOSName";
- $self->{'export-path'}
- = "$openslxConfig{'export-path'}/$exportType/$vendorOSName";
+ = "$openslxConfig{'private-path'}/stage1/$vendorOSName";
+ my $exportBasePath = "$openslxConfig{'public-path'}/export";
+ $self->{'export-path'} = "$exportBasePath/$exportType/$vendorOSName";
vlog 1, _tr("vendor-OS from '%s' will be exported to '%s'",
$self->{'vendor-os-path'}, $self->{'export-path'});
}
diff --git a/installer/OpenSLX/OSExport/ExportType/NBD_Squash.pm b/installer/OpenSLX/OSExport/ExportType/NBD_Squash.pm
index e2a558bd..a1ec0c26 100644
--- a/installer/OpenSLX/OSExport/ExportType/NBD_Squash.pm
+++ b/installer/OpenSLX/OSExport/ExportType/NBD_Squash.pm
@@ -183,7 +183,7 @@ sub createSquashFS
# ... invoke mksquashfs ...
vlog 0, _tr("invoking mksquashfs...");
my $mksquashfsBinary
- = "$openslxConfig{'share-path'}/squashfs/mksquashfs";
+ = "$openslxConfig{'base-path'}/share/squashfs/mksquashfs";
my $res = system("$mksquashfsBinary $source $target -ff $filterFile");
unlink($filterFile);
# ... remove filter file if done
diff --git a/installer/OpenSLX/OSExport/ExportType/NFS.pm b/installer/OpenSLX/OSExport/ExportType/NFS.pm
index bfe4ba1f..12fa4bfc 100644
--- a/installer/OpenSLX/OSExport/ExportType/NFS.pm
+++ b/installer/OpenSLX/OSExport/ExportType/NFS.pm
@@ -70,7 +70,8 @@ sub generateExportURI
: generatePlaceholderFor('serverip');
$server .= ":$export->{port}" if length($export->{port});
- return "nfs://$server$openslxConfig{'export-path'}/nfs/$vendorOS->{name}";
+ my $exportPath = "$openslxConfig{'public-path'}/export";
+ return "nfs://$server/$exportPath/nfs/$vendorOS->{name}";
}
sub requiredFSMods
diff --git a/installer/OpenSLX/OSSetup/Distro/Base.pm b/installer/OpenSLX/OSSetup/Distro/Base.pm
index 6ed6078c..769288f1 100644
--- a/installer/OpenSLX/OSSetup/Distro/Base.pm
+++ b/installer/OpenSLX/OSSetup/Distro/Base.pm
@@ -50,7 +50,7 @@ sub initialize
}
$self->{'stage1a-binaries'} = {
- "$openslxConfig{'share-path'}/busybox/busybox" => 'bin',
+ "$openslxConfig{'base-path'}/share/busybox/busybox" => 'bin',
};
$self->{'stage1b-faked-files'} = [
diff --git a/installer/OpenSLX/OSSetup/Engine.pm b/installer/OpenSLX/OSSetup/Engine.pm
index 35dbb32e..4d313e73 100644
--- a/installer/OpenSLX/OSSetup/Engine.pm
+++ b/installer/OpenSLX/OSSetup/Engine.pm
@@ -138,7 +138,7 @@ sub initialize
if ($actionType ne 'clone') {
# setup path to distribution-specific info:
my $sharedDistroInfoDir
- = "$openslxConfig{'share-path'}/distro-info/$distro->{'base-name'}";
+ = "$openslxConfig{'base-path'}/share/distro-info/$distro->{'base-name'}";
if (!-d $sharedDistroInfoDir) {
die _tr("unable to find shared distro-info in '%s'\n",
$sharedDistroInfoDir);
@@ -164,7 +164,7 @@ sub initialize
}
$self->{'vendor-os-path'}
- = "$openslxConfig{'stage1-path'}/$self->{'vendor-os-name'}";
+ = "$openslxConfig{'private-path'}/stage1/$self->{'vendor-os-name'}";
vlog 1, "vendor-OS path is '$self->{'vendor-os-path'}'";
if ($actionType ne 'clone') {
@@ -601,7 +601,7 @@ sub startLocalURLServersAsNeeded
= $self->hostIs64Bit()
? 'busybox.x86_64'
: 'busybox.i586';
- my $busybox = "$openslxConfig{'share-path'}/busybox/$busyboxName";
+ my $busybox = "$openslxConfig{'base-path'}/share/busybox/$busyboxName";
my $port = 5080;
if ($localURL =~ m[:(\d+)/]) {
$port = $1;
@@ -653,13 +653,13 @@ sub stage1A_createBusyboxEnvironment
= $self->hostIs64Bit()
? 'busybox.x86_64'
: 'busybox.i586';
- copyFile("$openslxConfig{'share-path'}/busybox/$busyboxName",
+ copyFile("$openslxConfig{'base-path'}/share/busybox/$busyboxName",
"$self->{stage1aDir}/bin", 'busybox');
# determine all required libraries and copy those, too:
vlog 1, _tr("calling slxldd for $busyboxName");
my $slxlddCmd
- = "slxldd $openslxConfig{'share-path'}/busybox/$busyboxName";
+ = "slxldd $openslxConfig{'base-path'}/share/busybox/$busyboxName";
vlog 2, "executing: $slxlddCmd";
my $requiredLibsStr = `$slxlddCmd`;
if ($?) {
@@ -682,7 +682,7 @@ sub stage1A_createBusyboxEnvironment
# create all needed links to busybox:
my $links
- = slurpFile("$openslxConfig{'share-path'}/busybox/busybox.links");
+ = slurpFile("$openslxConfig{'base-path'}/share/busybox/busybox.links");
foreach my $linkTarget (split "\n", $links) {
linkFile('/bin/busybox', "$self->{stage1aDir}/$linkTarget");
}
diff --git a/installer/default_files/hwdata/Cards.local b/installer/default_files/hwdata/Cards.local
index 94c15aa8..1bcf28b1 100644
--- a/installer/default_files/hwdata/Cards.local
+++ b/installer/default_files/hwdata/Cards.local
@@ -9,7 +9,7 @@
#
# General information about OpenSLX can be found under http://openslx.org
#
-# <SLX_SHARE_PATH>/share/templates/hwdata/Cards.local
+# <SLX_BASE_PATH>/share/templates/hwdata/Cards.local
#
# Local changes to the Cards file. All additions should be documented here,
# so that they are not lost ... They are prepended via mkdxsinitrd to the
diff --git a/installer/default_files/hwdata/pcitable.local b/installer/default_files/hwdata/pcitable.local
index c66ef550..5c7f370d 100644
--- a/installer/default_files/hwdata/pcitable.local
+++ b/installer/default_files/hwdata/pcitable.local
@@ -9,7 +9,7 @@
#
# General information about OpenSLX can be found under http://openslx.org
#
-# <SLX_SHARE_PATH>/share/templates/hwdata/pcitable.local
+# <SLX_BASE_PATH>/share/templates/hwdata/pcitable.local
#
# local changes to the pcitables file. All additions should be documented
# here, so that they are not lost ... the pcitable file seems to be part of
diff --git a/installer/slxos-export b/installer/slxos-export
index 91c81706..a29f2b4e 100755
--- a/installer/slxos-export
+++ b/installer/slxos-export
@@ -72,7 +72,7 @@ if ($action =~ m[^list-ex]i) {
# filter out RSYNC_TMP folders:
$_ !~ m[###];
}
- sort <$openslxConfig{'export-path'}/$type/*>);
+ sort <$openslxConfig{'public-path'}/export/$type/*>);
}
} elsif ($action =~ m[^list-in]i) {
print _tr("List of installed vendor-OSes:\n");
@@ -80,7 +80,7 @@ if ($action =~ m[^list-ex]i) {
s[^.+/][];
"\t$_\n";
}
- sort <$openslxConfig{'stage1-path'}/*>);
+ sort <$openslxConfig{'private-path'}/stage1/*>);
} elsif ($action =~ m[^list-ty]i) {
print _tr("List of supported export types:\n\t");
print join("\n\t", sort keys %supportedExportTypes)."\n";
@@ -275,23 +275,14 @@ slxsettings, slxos-setup, slxconfig, slxconfig-demuxer
Being a part of OpenSLX, this script supports several other options
which can be used to overrule the OpenSLX settings:
- --base-path=<string> basic path to project files
- --bin-path=<string> path to binaries and scripts
- --config-path=<string> path to configuration files
- --db-basepath=<string> basic path to openslx database
- --db-datadir=<string> data folder created under db-basepath
--db-name=<string> name of database
--db-spec=<string> full DBI-specification of database
--db-type=<string> type of database to connect to
- --export-path=<string> path to root of all exported filesystems
--locale=<string> locale to use for translations
--logfile=<string> file to write logging output to
--private-path=<string> path to private data
--public-path=<string> path to public (client-accesible) data
- --share-path=<string> path to sharable data
- --stage1-path=<string> path to stage1 systems
--temp-path=<string> path to temporary data
- --tftpboot-path=<string> path to root of tftp-server
--verbose-level=<int> level of logging verbosity (0-3)
Please refer to the C<slxsettings>-manpage for a more detailed description
diff --git a/installer/slxos-setup b/installer/slxos-setup
index bd0df5d5..1d6a0201 100755
--- a/installer/slxos-setup
+++ b/installer/slxos-setup
@@ -146,7 +146,7 @@ if ($action =~ m[^import]i) {
s[^.+/][];
"\t$_\n";
}
- sort <$openslxConfig{'stage1-path'}/*>);
+ sort <$openslxConfig{'private-path'}/stage1/*>);
} else {
print STDERR _tr("You need to specify exactly one action:
clone
@@ -349,23 +349,14 @@ slxsettings, slxos-export, slxconfig, slxconfig-demuxer
Being a part of OpenSLX, this script supports several other options
which can be used to overrule the OpenSLX settings:
- --base-path=<string> basic path to project files
- --bin-path=<string> path to binaries and scripts
- --config-path=<string> path to configuration files
- --db-basepath=<string> basic path to openslx database
- --db-datadir=<string> data folder created under db-basepath
--db-name=<string> name of database
--db-spec=<string> full DBI-specification of database
--db-type=<string> type of database to connect to
- --export-path=<string> path to root of all exported filesystems
--locale=<string> locale to use for translations
--logfile=<string> file to write logging output to
--private-path=<string> path to private data
--public-path=<string> path to public (client-accesible) data
- --share-path=<string> path to sharable data
- --stage1-path=<string> path to stage1 systems
--temp-path=<string> path to temporary data
- --tftpboot-path=<string> path to root of tftp-server
--verbose-level=<int> level of logging verbosity (0-3)
Please refer to the C<slxsettings>-manpage for a more detailed description