summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorJohn Southworth <john.southworth@vyatta.com>2011-06-28 11:32:51 -0500
committerJohn Southworth <john.southworth@vyatta.com>2011-06-28 11:32:51 -0500
commit296c15ab9819d01948f719cc09c1afd4e4265eca (patch)
treee181f18047c8f4148408121253d98ce42a339a4c /scripts
parent7047a00b552d83464a0a0e78285379098b75bf14 (diff)
downloadvyatta-op-296c15ab9819d01948f719cc09c1afd4e4265eca.tar.gz
vyatta-op-296c15ab9819d01948f719cc09c1afd4e4265eca.zip
Add a disk-install uri for old disk based installs in image tools
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/vyatta-image-tools.pl8
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/vyatta-image-tools.pl b/scripts/vyatta-image-tools.pl
index 1fd139c..2edeb10 100755
--- a/scripts/vyatta-image-tools.pl
+++ b/scripts/vyatta-image-tools.pl
@@ -46,6 +46,8 @@ sub conv_file {
}
if ( $topdir eq "running" ) {
$file = "/$file";
+ } elsif ( lc($topdir) eq 'disk-install' ) {
+ $file = "/live/image/$file";
} elsif ( lc($topdir) eq 'tftp') {
$file = $filein;
$topdir = 'url';
@@ -72,6 +74,8 @@ sub conv_file_to_rel {
my ($topdir, $filename) = @_;
if ($topdir eq "running"){
$filename =~ s?/?$topdir://?;
+ } elsif ($topdir eq "disk-install") {
+ $filename =~ s?/live/image/?$topdir://?;
} else {
$filename =~ s?/live/image/boot/$topdir/live-rw/?$topdir://?;
}
@@ -175,6 +179,10 @@ sub update {
print "Cannot clone to running\n";
exit 1;
}
+ if ($t_topdir eq 'disk-install'){
+ print "Cannot clone to running\n";
+ exit 1;
+ }
if ($t_topdir eq 'url'){
print "Cannot clone to a url\n";
exit 1;