You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by pd...@apache.org on 2015/03/08 15:32:54 UTC

[4/7] cloudstack-docs-admin git commit: Update templates.rst

Update templates.rst

echo does not print backslash-newline as a newline.
Use printf instead, and remove trailing spaces

Signed-off-by: Pierre-Luc Dion <pd...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack-docs-admin/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack-docs-admin/commit/4ee92ca1
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack-docs-admin/tree/4ee92ca1
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack-docs-admin/diff/4ee92ca1

Branch: refs/heads/master
Commit: 4ee92ca1c1add254d68bc3fde0d4dbe539522fea
Parents: 708cb99
Author: Martijn Koster <ma...@greenhills.co.uk>
Authored: Wed Feb 18 23:17:32 2015 +0000
Committer: Pierre-Luc Dion <pd...@apache.org>
Committed: Sun Mar 8 10:16:47 2015 -0400

----------------------------------------------------------------------
 source/templates.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack-docs-admin/blob/4ee92ca1/source/templates.rst
----------------------------------------------------------------------
diff --git a/source/templates.rst b/source/templates.rst
index 69480ad..0673032 100644
--- a/source/templates.rst
+++ b/source/templates.rst
@@ -414,7 +414,7 @@ templating.
              fqdn="$hostname.$(cat /var/lib/dhcp/dhclient.eth0.leases  |  awk ' /domain-name/ { domain = $3 }  END { printf     domain } ' | sed 's/[";]//g')"
              ip=$(cat /var/lib/dhcp/dhclient.eth0.leases  |  awk ' /fixed-address/ { lease = $2 }  END { printf lease } ' | sed     's/[";]//g')
              echo "cloudstack-hostname: Hostname _localhost_ detected. Changing hostname and adding hosts."
-             echo " Hostname: $hostname \n FQDN: $fqdn \n IP: $ip"
+             printf " Hostname: $hostname\n FQDN: $fqdn\n IP: $ip"
              # Update /etc/hosts
              awk -v i="$ip" -v f="$fqdn" -v h="$hostname" "/^127/{x=1} !/^127/ && x { x=0; print i,f,h; } { print $0; }" /etc/hosts > /etc/hosts.dhcp.tmp
              mv /etc/hosts /etc/hosts.dhcp.bak