network/NetworkManager: Hackery to set static hostname

Problem reported by Fırat Birlik on the NM mailing list:
http://mail.gnome.org/archives/networkmanager-list/2010-June/msg00105.html

Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
This commit is contained in:
Robby Workman 2010-06-22 05:59:12 -05:00
parent 56665ece6d
commit 3a608519b6
3 changed files with 10 additions and 1 deletions

View File

@ -24,7 +24,7 @@
PRGNAM=NetworkManager
VERSION=${VERSION:-0.8}
BUILD=${BUILD:-1}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
# Automatically determine the architecture we're building on:

View File

@ -22,6 +22,11 @@ preserve_perms() {
config ${NEW}
}
if [ -e etc/HOSTNAME ]; then
sed -i "s,yourhostname,$(cat etc/HOSTNAME | cut -f1 -d .)," \
etc/NetworkManager/nm-system-settings.conf.new
fi
preserve_perms etc/rc.d/rc.networkmanager.new
config etc/NetworkManager/nm-system-settings.conf.new

View File

@ -1,2 +1,6 @@
[main]
plugins=keyfile
[keyfile]
hostname=yourhostname