diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2017-06-01 15:49:31 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2017-06-03 10:41:09 +0200 |
| commit | 61a577885b4c69f9b33330d3562b2ffc0c1890fc (patch) | |
| tree | ed5627faadf8810b3632a564f12fefc9e6d94f77 /tools | |
| parent | ac2962a1c5914247b325ce0d1ba5c8bd5cc824e3 (diff) | |
tools: more reliable network config in create-gce-image.sh
Currently we append to /etc/network/interfaces,
which can lead to duplicate lo entry.
Write out the whole interfaces file instead.
Diffstat (limited to 'tools')
| -rwxr-xr-x | tools/create-gce-image.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/create-gce-image.sh b/tools/create-gce-image.sh index 59d7823fb..7204fb752 100755 --- a/tools/create-gce-image.sh +++ b/tools/create-gce-image.sh @@ -63,7 +63,7 @@ sudo cp -a $1/. disk.mnt/. sudo cp $2 disk.mnt/vmlinuz sudo sed -i "/^root/ { s/:x:/::/ }" disk.mnt/etc/passwd echo "T0:23:respawn:/sbin/getty -L ttyS0 115200 vt100" | sudo tee -a disk.mnt/etc/inittab -echo -en "\nauto eth0\niface eth0 inet dhcp\n" | sudo tee -a disk.mnt/etc/network/interfaces +echo -en "auto lo\niface lo inet loopback\nauto eth0\niface eth0 inet dhcp\n" | sudo tee disk.mnt/etc/network/interfaces echo "debugfs /sys/kernel/debug debugfs defaults 0 0" | sudo tee -a disk.mnt/etc/fstab echo "kernel.printk = 7 4 1 3" | sudo tee -a disk.mnt/etc/sysctl.conf echo "debug.exception-trace = 0" | sudo tee -a disk.mnt/etc/sysctl.conf |
