Easy switch of base distro for template ($DIST env var)
This commit is contained in:
parent
44a9f5a1d5
commit
179c658348
@ -3,15 +3,17 @@
|
||||
SRC_ROOT=../..
|
||||
[ -n "$1" ] && SRC_ROOT=$1
|
||||
|
||||
: DIST=fc14
|
||||
|
||||
rm -fr rpms_to_install/*
|
||||
VERSION_CORE=$(cat version_core)
|
||||
VERSION_CORE=$(cat version_core | sed "s/DIST/$DIST/")
|
||||
ln -s $SRC_ROOT/core/rpm/x86_64/qubes-core-appvm-$VERSION_CORE.rpm rpms_to_install/qubes-core-appvm
|
||||
ln -s $SRC_ROOT/core/rpm/x86_64/qubes-core-appvm-libs-$VERSION_CORE.rpm rpms_to_install/qubes-core-appvm-libs
|
||||
ln -s $SRC_ROOT/core/rpm/x86_64/qubes-core-commonvm-$VERSION_CORE.rpm rpms_to_install/qubes-core-commonvm
|
||||
ln -s $SRC_ROOT/core/rpm/x86_64/qubes-core-netvm-$VERSION_CORE.rpm rpms_to_install/qubes-core-netvm
|
||||
ln -s $SRC_ROOT/core/rpm/x86_64/qubes-core-proxyvm-$VERSION_CORE.rpm rpms_to_install/qubes-core-proxyvm
|
||||
|
||||
VERSION_GUI=$(cat version_gui)
|
||||
VERSION_GUI=$(cat version_gui | sed "s/DIST/$DIST/")
|
||||
ln -s $SRC_ROOT/gui/rpm/x86_64/qubes-gui-vm-$VERSION_GUI.rpm rpms_to_install/qubes-gui-vm
|
||||
|
||||
VERSION_XEN=$(cat version_xen)
|
||||
|
@ -3,6 +3,8 @@
|
||||
IMG=$1
|
||||
PKGLISTFILE=$2
|
||||
|
||||
: ${DIST=fc14}
|
||||
|
||||
if ! [ $# -eq 2 ]; then
|
||||
echo "usage $0 <img_file_name> <package_list>"
|
||||
exit
|
||||
@ -15,6 +17,11 @@ if [ -f $IMG ]; then
|
||||
INSTALLDIR=`pwd`/mnt/
|
||||
else
|
||||
|
||||
echo "-> Preparing instalation of $DIST template..."
|
||||
rm -f keys base_rpms
|
||||
ln -sf keys_$DIST keys
|
||||
ln -sf base_rpms_$DIST base_rpms
|
||||
|
||||
echo "-> Initializing empty image..."
|
||||
truncate -s 10G $IMG || exit 1
|
||||
|
||||
@ -31,9 +38,7 @@ else
|
||||
rpm --import --root=$INSTALLDIR keys/*
|
||||
|
||||
echo "-> Installing core RPM packages..."
|
||||
rpm -i --root=$INSTALLDIR base_rpms/setup-*.rpm
|
||||
rpm -i --root=$INSTALLDIR base_rpms/filesystem-*.rpm
|
||||
rpm -i --root=$INSTALLDIR base_rpms/fedora-release-*.rpm
|
||||
rpm -i --root=$INSTALLDIR base_rpms/*.rpm
|
||||
|
||||
cp clean_images/network $INSTALLDIR/etc/sysconfig
|
||||
cp clean_images/resolv.conf $INSTALLDIR/etc
|
||||
|
@ -1 +1 @@
|
||||
1.6.29-1.fc14.x86_64
|
||||
1.6.29-1.DIST.x86_64
|
||||
|
@ -1 +1 @@
|
||||
1.3.6-1.fc14.x86_64
|
||||
1.3.6-1.DIST.x86_64
|
||||
|
Loading…
Reference in New Issue
Block a user