Changeset 6692


Ignore:
Timestamp:
Jan 25, 2018, 3:00:21 PM (21 months ago)
Author:
kbut
Message:

set mirror is exists

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lmd/trunk/fuentes/lmd-lliurex-data.install/usr/share/ltsp/plugins/ltsp-build-client/ISO/000-unsquash-iso

    r6680 r6692  
    2626                        set -e
    2727                        chroot $ROOT apt-get $APT_GET_OPTS update && echo si || { mv $ROOT/etc/apt/sources.list $ROOT/etc/apt/sources.list.old;}
     28                        mv $ROOT/etc/apt/sources.list $ROOT/etc/apt/sources.list.old
    2829                        set +e
    29                         echo "deb http://lliurex.net/xenial xenial main restricted universe multiverse" >> $ROOT/etc/apt/sources.list.d/lliurex.temp.list
    30                         echo "deb http://lliurex.net/xenial xenial-updates main restricted universe multiverse" >> $ROOT/etc/apt/sources.list.d/lliurex.temp.list
    31                         echo "deb http://lliurex.net/xenial xenial-security main restricted universe multiverse" >> $ROOT/etc/apt/sources.list.d/lliurex.temp.list
     30                        n4d-client -m is_mirror_available -c MirrorManager | grep 'True'
     31                        rc=$?
     32                        if [ '$rc' = '0' ]; then
     33                                echo "deb http://mirror/llx16 xenial main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     34                                echo "deb http://mirror/llx16 xenial-updates main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     35                                echo "deb http://mirror/llx16 xenial-security main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     36                        else
     37                                echo "deb http://lliurex.net/xenial xenial main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     38                                echo "deb http://lliurex.net/xenial xenial-updates main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     39                                echo "deb http://lliurex.net/xenial xenial-security main restricted universe multiverse" >> $ROOT/etc/apt/sources.list
     40                        fi
    3241                        chroot $ROOT apt-get $APT_GET_OPTS update
    3342                else
     
    4049        ;;
    4150        finalization)
    42                 rm $ROOT/etc/apt/sources.list.d/lliurex.temp.list
    4351                chroot $ROOT apt-get $APT_GET_OPTS purge lliurex-meta-live
    4452                chroot $ROOT dpkg-reconfigure openssh-server
    45                
    4653        ;;
    4754esac
Note: See TracChangeset for help on using the changeset viewer.