From b7f319d84901032ccc4458df8e0a3e07d3c1e54a Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sun, 9 Aug 2015 11:37:40 +0100 Subject: [PATCH] hostname --- src/freedombone | 1 + src/freedombone-client | 1 + 2 files changed, 2 insertions(+) diff --git a/src/freedombone b/src/freedombone index 9b01bfee..0ce29319 100755 --- a/src/freedombone +++ b/src/freedombone @@ -1804,6 +1804,7 @@ function mesh_batman_bridge { echo ' echo "error: unable to find wifi interface, not enabling batman-adv mesh"' >> $batman_script echo ' return' >> $batman_script echo ' fi' >> $batman_script + echo ' sed -i "s|hosts:.*|hosts: files mdns4_minimal [NOTFOUND=return] dns $(hostname)|g" /etc/nsswitch.conf' >> $batman_script echo ' echo "info: enabling batman-adv mesh network $ESSID on $IFACE"' >> $batman_script echo ' systemctl stop network-manager' >> $batman_script echo ' sleep 5' >> $batman_script diff --git a/src/freedombone-client b/src/freedombone-client index 97a1ca5b..4f8c0983 100755 --- a/src/freedombone-client +++ b/src/freedombone-client @@ -179,6 +179,7 @@ function mesh_batman { echo ' apt-get -y install avahi-utils avahi-autoipd avahi-daemon avahi-dnsconfd' >> $batman_script echo ' sed -i "s|#host-name=.*|host-name=$(hostname)|g" /etc/avahi/avahi-daemon.conf' >> $batman_script echo ' sed -i "s|host-name=.*|host-name=$(hostname)|g" /etc/avahi/avahi-daemon.conf' >> $batman_script + echo ' sed -i "s|hosts:.*|hosts: files mdns4_minimal [NOTFOUND=return] dns $(hostname)|g" /etc/nsswitch.conf' >> $batman_script echo 'fi' >> $batman_script echo '' >> $batman_script echo '# Mesh definition' >> $batman_script