[PATCH] Add a mirrorlist option.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This option allows us to pass a mirrorlist into buildinstall instead of or in
addition to baseurls.  This will allow the yum object to make use of a list of
potential mirrors should it have difficulties downloading something.
---
 scripts/buildinstall |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/scripts/buildinstall b/scripts/buildinstall
index 4266d83..829d33c 100755
--- a/scripts/buildinstall
+++ b/scripts/buildinstall
@@ -67,6 +67,10 @@ while [ $# -gt 0 ]; do
 	    UPDATES=$2
 	    shift; shift
 	    ;;
+	--mirrorlist)
+	    MIRRORLIST="$MIRRORLIST $2"
+	    shift; shift
+	    ;;
 
 	*)
         if [ -z "$REPO" ]; then
@@ -142,6 +146,19 @@ EOF
     let n++
 done
 
+n=1
+for l in $MIRRORLIST; do
+    cat >> $yumconf <<EOF
+
+[anaconda-mirrorlistrepo-$n]
+name=anaconda mirrorlist repo $n
+mirrorlist=$l
+enabled=1
+EOF
+    let n++
+done
+
+
 
 BUILDINSTDIR=`mktemp -d ${TMPDIR:-/tmp}/buildinstall.tree.XXXXXX`
 TREEDIR=`mktemp -d ${TMPDIR:-/tmp}/treedir.XXXXXX`
-- 
1.5.5.2

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux