diff options
author | Will Woods <wwoods@redhat.com> | 2012-04-02 22:14:24 -0400 |
---|---|---|
committer | Will Woods <wwoods@redhat.com> | 2012-04-03 16:37:45 -0400 |
commit | 0f4773a15dfd31c77b35ec5d8b2af7b1dd5b9c2c (patch) | |
tree | 7941934fc942f88ad936eb0768a0738508d8059c /dracut/parse-anaconda-repo.sh | |
parent | fd3742ad638437010800e45f9b36e9cc23d530f7 (diff) | |
download | anaconda-0f4773a15dfd31c77b35ec5d8b2af7b1dd5b9c2c.tar.gz anaconda-0f4773a15dfd31c77b35ec5d8b2af7b1dd5b9c2c.tar.xz anaconda-0f4773a15dfd31c77b35ec5d8b2af7b1dd5b9c2c.zip |
support {stage2,repo}=.../path/to/file.img (#808499)
preupgrade uses stage2=hd:XXX:/path/upgrade.img, so we need to handle
that.
stage2=XXX overrides repo=XXX, if both are present.
Diffstat (limited to 'dracut/parse-anaconda-repo.sh')
-rwxr-xr-x | dracut/parse-anaconda-repo.sh | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/dracut/parse-anaconda-repo.sh b/dracut/parse-anaconda-repo.sh index 1b0445a69..96de45809 100755 --- a/dracut/parse-anaconda-repo.sh +++ b/dracut/parse-anaconda-repo.sh @@ -5,16 +5,21 @@ getarg root= >/dev/null && return repo="$(getarg repo= inst.repo=)" +stage2="$(getarg stage2= inst.stage2=)" + +arg="repo" +# default to using repo, but if we have stage2=, use that +[ -n "$stage2" ] && arg="stage2" && repo="$stage2" if [ -n "$repo" ]; then splitsep ":" "$repo" repotype rest case "$repotype" in http|https|ftp|nfs|nfs4|nfsiso) - set_neednet; root="anaconda-net" ;; + set_neednet; root="anaconda-net:$repo" ;; hd|cd|cdrom) [ -n "$rest" ] && root="anaconda-disk:$rest" ;; *) - warn "Invalid value for 'inst.repo': $repo" ;; + warn "Invalid value for 'inst.$arg': $repo" ;; esac fi |