fix resolv.conf for ubuntu-touch initramfs creation

This commit is contained in:
Oliver Grawert 2013-05-29 12:12:41 +02:00
parent ef88505296
commit c4064d69e0
2 changed files with 18 additions and 0 deletions

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
livecd-rootfs (2.139) UNRELEASED; urgency=low
* fix resolv.conf for ubuntu-touch initramfs creation
-- Oliver Grawert <ogra@ubuntu.com> Wed, 29 May 2013 12:10:53 +0200
livecd-rootfs (2.138) saucy; urgency=low
* also move the sources.list.d dir out of the way on ubuntu-touch

View File

@ -412,6 +412,13 @@ if [ "$PROJECT" = "ubuntu-touch" ] && [ "$ARCH" = "armhf" ]; then
lb chroot_sysfs install "$@"
lb chroot_devpts install "$@"
if [ -e chroot/etc/resolv.conf ]; then
mv chroot/etc/resolv.conf chroot/etc/resolv.conf.orig
fi
if [ -e /etc/resolv.conf ]; then
cp /etc/resolv.conf chroot/etc/resolv.conf
fi
mv "${sourceslist}" "${sourceslist}.orig"
mv "${sourceslist}.d" "${sourceslist}.d.orig"
echo "deb http://ftpmaster.internal/ubuntu/ $codename main universe" >$sourceslist
@ -445,6 +452,11 @@ if [ "$PROJECT" = "ubuntu-touch" ] && [ "$ARCH" = "armhf" ]; then
for file in $(find chroot/var/lib/apt/lists/ -name ftpmaster.internal*); do
rm $file
done
if [ -e chroot/etc/resolv.conf.orig ]; then
mv chroot/etc/resolv.conf.orig chroot/etc/resolv.conf
else
rm chroot/etc/resolv.conf
fi
fi
# LTSP chroot building (only in 32bit and for Edubuntu (DVD))