[Debian-live-changes] r2300 - dists/trunk/live-helper/helpers
daniel at alioth.debian.org
daniel at alioth.debian.org
Sat Jun 30 17:17:36 UTC 2007
Author: daniel
Date: 2007-06-30 17:17:36 +0000 (Sat, 30 Jun 2007)
New Revision: 2300
Modified:
dists/trunk/live-helper/helpers/lh_binary
dists/trunk/live-helper/helpers/lh_chroot
dists/trunk/live-helper/helpers/lh_chroot_hostname
dists/trunk/live-helper/helpers/lh_chroot_hosts
dists/trunk/live-helper/helpers/lh_chroot_resolv
dists/trunk/live-helper/helpers/lh_source
Log:
Modified: dists/trunk/live-helper/helpers/lh_binary
===================================================================
--- dists/trunk/live-helper/helpers/lh_binary 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_binary 2007-06-30 17:17:36 UTC (rev 2300)
@@ -30,9 +30,9 @@
# Configuring chroot
lh_chroot_proc install ${*}
lh_chroot_sysfs install ${*}
-lh_chroot_hostname install ${*}
lh_chroot_hosts install ${*}
lh_chroot_resolv install ${*}
+lh_chroot_hostname install ${*}
lh_chroot_sources install ${*}
# Building root filesystem
@@ -62,8 +62,8 @@
# Deconfiguring chroot
rm -f .stage/chroot_sources
+lh_chroot_hostname remove ${*}
lh_chroot_resolv remove ${*}
lh_chroot_hosts remove ${*}
-lh_chroot_hostname remove ${*}
lh_chroot_sysfs remove ${*}
lh_chroot_proc remove ${*}
Modified: dists/trunk/live-helper/helpers/lh_chroot
===================================================================
--- dists/trunk/live-helper/helpers/lh_chroot 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_chroot 2007-06-30 17:17:36 UTC (rev 2300)
@@ -38,9 +38,9 @@
lh_chroot_sysfs install ${*}
lh_chroot_debianchroot install ${*}
lh_chroot_sysvrc install ${*}
-lh_chroot_hostname install ${*}
lh_chroot_hosts install ${*}
lh_chroot_resolv install ${*}
+lh_chroot_hostname install ${*}
lh_chroot_apt install ${*}
lh_chroot_sources install ${*}
lh_chroot_linux-image install ${*}
@@ -65,9 +65,9 @@
lh_chroot_linux-image remove ${*}
lh_chroot_sources remove ${*}
lh_chroot_apt remove ${*}
+lh_chroot_hostname remove ${*}
lh_chroot_resolv remove ${*}
lh_chroot_hosts remove ${*}
-lh_chroot_hostname remove ${*}
lh_chroot_sysvrc remove ${*}
lh_chroot_debianchroot remove ${*}
lh_chroot_sysfs remove ${*}
Modified: dists/trunk/live-helper/helpers/lh_chroot_hostname
===================================================================
--- dists/trunk/live-helper/helpers/lh_chroot_hostname 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_chroot_hostname 2007-06-30 17:17:36 UTC (rev 2300)
@@ -51,15 +51,15 @@
if [ -f chroot/etc/hostname ]
then
# Save hostname file
- cp chroot/etc/hostname chroot/etc/hostname.orig
+ mv chroot/etc/hostname chroot/etc/hostname.orig
fi
- if [ -f /etc/hostname ]
- then
- # Copy hostname file
- cp /etc/hostname chroot/etc/hostname
- fi
+ # Create hostname file
+ echo "localhost.localdomain" > chroot/etc/hostname
+ # Set hostname
+ Chroot "hostname -F /etc/hostname"
+
# Creating stage file
Create_stagefile .stage/chroot_hostname
;;
Modified: dists/trunk/live-helper/helpers/lh_chroot_hosts
===================================================================
--- dists/trunk/live-helper/helpers/lh_chroot_hosts 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_chroot_hosts 2007-06-30 17:17:36 UTC (rev 2300)
@@ -51,13 +51,21 @@
if [ -f chroot/etc/hosts ]
then
# Save hosts file
- cp chroot/etc/hosts chroot/etc/hosts.orig
+ mv chroot/etc/hosts chroot/etc/hosts.orig
fi
+ # Creating hosts file
+
+cat > chroot/etc/hosts << EOF
+127.0.0.1 localhost localhost.localdomain
+127.0.1.1 debian
+EOF
+
if [ -f /etc/hosts ]
then
- # Copy hosts file
- cp /etc/hosts chroot/etc/hosts
+ # Append hosts file
+ #grep -e "127.0.0.1" -e "127.0.1.1" /etc/hosts >> chroot/etc/hosts
+ cat /etc/hosts >> chroot/etc/hosts
fi
# Creating stage file
Modified: dists/trunk/live-helper/helpers/lh_chroot_resolv
===================================================================
--- dists/trunk/live-helper/helpers/lh_chroot_resolv 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_chroot_resolv 2007-06-30 17:17:36 UTC (rev 2300)
@@ -51,7 +51,7 @@
if [ -f chroot/etc/resolv.conf ]
then
# Save resolv file
- cp chroot/etc/resolv.conf chroot/etc/resolv.conf.orig
+ mv chroot/etc/resolv.conf chroot/etc/resolv.conf.orig
fi
if [ -f /etc/resolv.conf ]
Modified: dists/trunk/live-helper/helpers/lh_source
===================================================================
--- dists/trunk/live-helper/helpers/lh_source 2007-06-30 16:56:34 UTC (rev 2299)
+++ dists/trunk/live-helper/helpers/lh_source 2007-06-30 17:17:36 UTC (rev 2300)
@@ -33,9 +33,9 @@
Set_defaults
# Enabling network in chroot
-lh_chroot_hostname install ${*}
lh_chroot_hosts install ${*}
lh_chroot_resolv install ${*}
+lh_chroot_hostname install ${*}
lh_chroot_sources install ${*}
# Preparing images
@@ -52,6 +52,6 @@
# Deconfiguring chroot
rm -f .stage/chroot_sources
+lh_chroot_hostname remove ${*}
lh_chroot_resolv remove ${*}
lh_chroot_hosts remove ${*}
-lh_chroot_hostname remove ${*}
More information about the Debian-live-changes
mailing list