diff options
author | Robert Bays <rbays@moresby.vyatta.com> | 2008-09-16 17:34:54 -0700 |
---|---|---|
committer | Robert Bays <rbays@moresby.vyatta.com> | 2008-09-16 17:34:54 -0700 |
commit | 3315ecc30e870af4ae8f97e0f8fce47d76fec6fa (patch) | |
tree | 1feed020d4c88ef366487f74ffca372a86d9a2fb /scripts/install-system | |
parent | 17b8a213217d50510cb318be840719875a27fa01 (diff) | |
download | vyatta-cfg-quagga-3315ecc30e870af4ae8f97e0f8fce47d76fec6fa.tar.gz vyatta-cfg-quagga-3315ecc30e870af4ae8f97e0f8fce47d76fec6fa.zip |
change to native install from a USB stick
Diffstat (limited to 'scripts/install-system')
-rwxr-xr-x | scripts/install-system | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/scripts/install-system b/scripts/install-system index 6048be62..33f54534 100755 --- a/scripts/install-system +++ b/scripts/install-system @@ -651,6 +651,7 @@ create_partitions() { # $1 is the partition to install on install_root_filesystem () { ldrive=$1 + version=$(egrep -i version /opt/vyatta/etc/version | awk '{ print $3 }') dpkg="/usr/bin/dpkg --force-all --root=$rootfsdir" echo "Mounting /dev/$ldrive " @@ -674,8 +675,15 @@ install_root_filesystem () { progress_indicator start # Mount the squashfs for copying output=$(mkdir -p /mnt/squashfs) - output=$(mount /live/image/live/filesystem.squashfs /mnt/squashfs -t squashfs -o loop) - status=$? + if [ -f /live/image/live/filesystem.squashfs ]; then + output=$(mount /live/image/live/filesystem.squashfs /mnt/squashfs -t squashfs -o loop) + status=$? + elif [ -f /live/image/boot/$version/$version.squashfs ]; then + output=$(mount /live/image/boot/$version/$version.squashfs /mnt/squashfs -t squashfs -o loop) + status=$? + else + echo -e "Error: Unable to find a squash image. \nExiting..." + fi if [ "$status" != 0 ]; then echo -e "Error trying to mount the squashfs.\nPlease see install log for more details.\nExiting..." @@ -713,7 +721,6 @@ install_root_filesystem () { progress_indicator stop echo "OK" else - version=$(egrep -i version /opt/vyatta/etc/version | awk '{ print $3 }') mkdir -p $rootfsdir/boot/$version if [ -f /live/image/live/filesystem.squashfs ]; then echo Copying squashfs image... |