Update task about selinux set.

1.Fix the invalid value about selinux policy
2.Update description of task about selinux.The permissive mode
need enable selinux.The parameter named "disable_selinux" is not good.
In order to customize selinux modes, we need a new
parameter named "selinux_state".

Closes-Bug: #1749046
Change-Id: I20c084cf2e46cc0de149afbd34c6dcb77a1051f4
This commit is contained in:
pengdake 2018-01-31 21:41:41 +08:00
parent 437d232dc4
commit 4f98f08ffa
3 changed files with 13 additions and 5 deletions

View File

@ -12,7 +12,9 @@ create_kolla_user: True
enable_host_ntp: True enable_host_ntp: True
disable_selinux: True change_selinux: True
selinux_state: "permissive"
docker_storage_driver: "" docker_storage_driver: ""

View File

@ -115,13 +115,13 @@
- ansible_os_family == "RedHat" - ansible_os_family == "RedHat"
- enable_host_ntp | bool - enable_host_ntp | bool
- name: Disable selinux - name: Change state of selinux
selinux: selinux:
policy: target policy: targeted
state: permissive state: "{{ selinux_state }}"
become: true become: true
when: when:
- disable_selinux | bool - change_selinux | bool
- ansible_os_family == "RedHat" - ansible_os_family == "RedHat"
- name: Reboot - name: Reboot

View File

@ -0,0 +1,6 @@
---
features:
- |
Add a new parameter for changing selinux state. The default value is
"permissive". Update a parameter named "disable_selinux", use
"change_selinux" instead of it.