Fix tr syntax in 51-hosts

Add single quotes to avoid shell expansion

Closes-Bug: 1633523
Change-Id: I9d586c867077909b5df8dc0fbf09e581f2e4ce16
This commit is contained in:
Matthew Flusche 2016-10-12 16:06:24 +00:00
parent fae231acf5
commit 8692ae9caf
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ write_entries() {
ENTRIES=$(os-apply-config --key hosts --type raw --key-default '' | tr '[A-Z]' '[a-z]')
if [ ! -z "$ENTRIES" ]; then
# cloud-init files are /etc/cloud/templates/hosts.OSNAME.tmpl
DIST=$(lsb_release -is | tr -s [A-Z] [a-z])
DIST=$(lsb_release -is | tr -s '[A-Z]' '[a-z]')
case $DIST in
fedora|redhatenterpriseserver)
name="redhat"