Add hostname to /etc/hosts

This commit is contained in:
Serge Schneider 2019-11-06 14:33:07 +00:00
parent d30343f626
commit 95ba042c83
3 changed files with 1 additions and 10 deletions

View file

@ -1,9 +0,0 @@
Index: jessie-stage1/rootfs/etc/hosts
===================================================================
--- jessie-stage1.orig/rootfs/etc/hosts
+++ jessie-stage1/rootfs/etc/hosts
@@ -3,3 +3,4 @@
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
+127.0.1.1 raspberrypi

View file

@ -1 +0,0 @@
01-hosts.diff

View file

@ -1,5 +1,6 @@
#!/bin/bash -e
echo "${HOSTNAME}" > "${ROOTFS_DIR}/etc/hostname"
echo "127.0.1.1 ${HOSTNAME}" >> "${ROOTFS_DIR}/etc/hosts"
ln -sf /dev/null "${ROOTFS_DIR}/etc/systemd/network/99-default.link"