projects
/
grml-debootstrap.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rewrote interfaces() code for handling of /etc/network/interfaces.
[grml-debootstrap.git]
/
chroot-script
diff --git
a/chroot-script
b/chroot-script
index
bc93353
..
9e1437f
100644
(file)
--- a/
chroot-script
+++ b/
chroot-script
@@
-270,13
+270,20
@@
hosts() {
# set up /etc/network/interfaces {{{
interfaces() {
# set up /etc/network/interfaces {{{
interfaces() {
- if ! [ -f /etc/network/interfaces ] ; then
+ touch /etc/network/interfaces
+ # make sure we add the entries only once
+ if ! grep -q eth0 /etc/network/interfaces ; then
echo "Setting up /etc/network/interfaces"
cat >> /etc/network/interfaces << EOF
echo "Setting up /etc/network/interfaces"
cat >> /etc/network/interfaces << EOF
+
+# loopback device:
iface lo inet loopback
iface lo inet loopback
-iface eth0 inet dhcp
auto lo
auto lo
-auto eth0
+
+# eth0:
+# iface eth0 inet dhcp
+# auto eth0
+
EOF
fi
}
EOF
fi
}