Proper selinux logic for Horizon

According to here:
http://docs.puppetlabs.com/learning/variables.html
"all facts are strings, and all non-empty strings,
 including the string "false" . are true"

Checking "if $::selinux" will always return true,
just like (if 'hello':) in python will always return true.

This uses str2bool to ensure that the variable is evaluated as a boolean.

Change-Id: I9489c3bd9a217c80762f5875f026676268572d79
This commit is contained in:
Logan McNaughton
2013-08-02 14:00:15 +00:00
parent 8840838298
commit ac5be9605f

View File

@@ -101,7 +101,7 @@ class openstack::horizon (
api_result_limit => $api_result_limit, api_result_limit => $api_result_limit,
} }
if $::selinux and $::selinux != 'false' { if str2bool($::selinux) {
selboolean{'httpd_can_network_connect': selboolean{'httpd_can_network_connect':
value => on, value => on,
persistent => true, persistent => true,