Commit 4da34f8e authored by Ryan Jackson's avatar Ryan Jackson
Browse files

Linux MFS: Set hostname based on project and experiment name

Set the hostname based on project and experiment name using
sethostname.dhclient as we do on other images.
parent 4e008896
......@@ -53,6 +53,14 @@ case "$1" in
echo adding dns $i
echo nameserver $i >> $RESOLV_CONF
done
if [ -n "$hostname" ]; then
hostname $hostname
if [ -x /usr/share/udhcpc/sethostname.dhclient ]; then
/usr/share/udhcpc/sethostname.dhclient
fi
fi
# XXX For now assume that this is the control net.
# The 'true' below should be changed to actually test
# whether this actually is the control net.
......
......@@ -56,6 +56,7 @@ script-install:
mkdir -p $(TARGET_PATH)/var/emulab/boot
mkdir -p $(TARGET_PATH)/var/emulab/db
ln -sf /etc/testbed $(TARGET_PATH)/usr/local/etc/emulab
install -m 755 $(TESTBEDOBJ_PATH)/tmcd/linux/sethostname.dhclient $(TARGET_PATH)/usr/share/udhcpc
install -m 755 $(TMCD_PATH)/linux/control_interface $(TARGET_PATH)/etc/testbed
install -m 755 $(TMCD_PATH)/linux/rc.frisbee $(TARGET_PATH)/etc/testbed
install -m 755 $(TMCD_PATH)/linux/rc.ipod $(TARGET_PATH)/etc/testbed
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment