diff options
author | Oliver Tappe | 2006-09-22 15:13:07 +0200 |
---|---|---|
committer | Oliver Tappe | 2006-09-22 15:13:07 +0200 |
commit | 8882da5b69b03af9a41040ff655eab06ec185ec2 (patch) | |
tree | 181023364dc2044a0dd9c7917d04316089121554 /config-db/OpenSLX/ConfigDB.pm | |
parent | * if NFSROOT contains @@@server_ip@@@, it is now replaces by the real server-... (diff) | |
download | core-8882da5b69b03af9a41040ff655eab06ec185ec2.tar.gz core-8882da5b69b03af9a41040ff655eab06ec185ec2.tar.xz core-8882da5b69b03af9a41040ff655eab06ec185ec2.zip |
* added support for correct auto-generation of export_uri, such that the configuration should be
independent of server-IPs
git-svn-id: http://svn.openslx.org/svn/openslx/trunk@386 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'config-db/OpenSLX/ConfigDB.pm')
-rw-r--r-- | config-db/OpenSLX/ConfigDB.pm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/config-db/OpenSLX/ConfigDB.pm b/config-db/OpenSLX/ConfigDB.pm index 3db779e2..4376ec68 100644 --- a/config-db/OpenSLX/ConfigDB.pm +++ b/config-db/OpenSLX/ConfigDB.pm @@ -806,6 +806,15 @@ sub aggregatedSystemFileInfosOfSystem my $kernelPath = "$openslxConfig{'private-path'}/stage1/$vendorOS->{path}"; + my $exportURI = $system->{'export_uri'}; + if ($exportURI !~ m[\w]) { + # auto-generate export_uri if none has been given: + my $type = $system->{'export_type'}; + my $serverIpToken = '@@@server_ip@@@'; + $exportURI + = "$type://$serverIpToken$openslxConfig{'public-path'}/$type/$vendorOS->{path}"; + } + my @variantIDs = fetchSystemVariantIDsOfSystem($confDB, $system->{id}); my @variants = fetchSystemVariantsByID($confDB, \@variantIDs); @@ -814,6 +823,7 @@ sub aggregatedSystemFileInfosOfSystem next if !length($sys->{kernel}); my %info = %$sys; $info{'kernel-file'} = "$kernelPath/$sys->{kernel}"; + $info{'export-uri'} = $exportURI; if (!defined $info{'name'}) { # compose full name and label for system-variant: $info{'name'} = "$system->{name}-$info{name_addition}"; |