Commit 0f3fe9e0 by Serge E. Hallyn Committed by Daniel Lezcano

lxc-clone: fix dhclient.conf send hostname command

End the command with ';', which is needed, and put the hostname in quotes (which doesn't really seem needed, but shown in man page). Signed-off-by: 's avatarSerge Hallyn <serge.hallyn@canonical.com> Signed-off-by: 's avatarDaniel Lezcano <dlezcano@fr.ibm.com>
parent 6f7c8b02
...@@ -252,7 +252,7 @@ echo "Updating rootfs..." ...@@ -252,7 +252,7 @@ echo "Updating rootfs..."
# so you can 'ssh $hostname.' or 'ssh $hostname.local' # so you can 'ssh $hostname.' or 'ssh $hostname.local'
if [ -f $rootfs/etc/dhcp/dhclient.conf ]; then if [ -f $rootfs/etc/dhcp/dhclient.conf ]; then
sed -i "s/send host-name.*$/send host-name $hostname/" $rootfs/etc/dhcp/dhclient.conf sed -i "s/send host-name.*$/send host-name \"$hostname\";/" $rootfs/etc/dhcp/dhclient.conf
fi fi
# set the hostname # set the hostname
......
Markdown is supported
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