mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 12:03:31 +01:00
integrate-distro.sh: Generate /etc/hosts from content entirely defined in the script
This commit is contained in:
parent
89ca484a66
commit
1b4166e798
1 changed files with 13 additions and 7 deletions
|
|
@ -476,14 +476,20 @@ EOT
|
|||
|
||||
make_etc_hosts()
|
||||
{
|
||||
cat /etc/hosts
|
||||
|
||||
# TODO: there must be an easier frontend for gethostbyname()
|
||||
local ftp_ip=`ping -c 1 ftp | sed '/PING/ !d; s/.*(\([0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+\)).*/\1/'`
|
||||
|
||||
# TODO: undo or - better yet - obviate the need for this
|
||||
_cat<<EOT
|
||||
|$ftp_ip ftp
|
||||
|127.0.0.1 localhost
|
||||
|
|
||||
|# special IPv6 addresses
|
||||
|::1 localhost ipv6-localhost ipv6-loopback
|
||||
|
|
||||
|fe00::0 ipv6-localnet
|
||||
|
|
||||
|ff00::0 ipv6-mcastprefix
|
||||
|ff02::1 ipv6-allnodes
|
||||
|ff02::2 ipv6-allrouters
|
||||
|ff02::3 ipv6-allhosts
|
||||
|127.0.0.1 ldap.lcl
|
||||
|127.0.0.1 ftp.priv.lcl
|
||||
EOT
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue