summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJasper Capel <jasper@newnewyork.nl>2009-02-26 17:47:01 +0100
committerJasper Capel <capel@stone-it.com>2009-02-27 16:34:38 +0100
commit00d82651e40b14325acf6f7d16673abd40cf3a42 (patch)
tree8ab8b82c40f52d14a732b6eaa004480ca06af79c
parent731210d77044ee424d9aab534feeced5931ce1d0 (diff)
downloadcobbler-00d82651e40b14325acf6f7d16673abd40cf3a42.tar.gz
cobbler-00d82651e40b14325acf6f7d16673abd40cf3a42.tar.xz
cobbler-00d82651e40b14325acf6f7d16673abd40cf3a42.zip
Set hostname correctly during %post
-rw-r--r--snippets/post_install_network_config3
1 files changed, 3 insertions, 0 deletions
diff --git a/snippets/post_install_network_config b/snippets/post_install_network_config
index dcc239ce..8715e778 100644
--- a/snippets/post_install_network_config
+++ b/snippets/post_install_network_config
@@ -59,6 +59,9 @@ grep -v HOSTNAME /etc/sysconfig/network > /etc/sysconfig/network.cobbler
echo "HOSTNAME=$hostname" >> /etc/sysconfig/network.cobbler
rm -f /etc/sysconfig/network
mv /etc/sysconfig/network.cobbler /etc/sysconfig/network
+ # Also set the hostname now, some applications require it (e.g.: if we're
+ # connecting to Puppet before a reboot).
+/bin/hostname $hostname
#end if
## =============================================================================
## now create the config file for each interface