ansible 之 seboolean
seboolean
用途:开启或关闭 SELinux
的 booleans
官方文档
> SEBOOLEAN (/usr/lib/python2.7/site-packages/ansible-2.8.0.dev0-py2.7.egg/ansible/modules/system/seboolean.
Toggles SELinux booleans.
* This module is maintained by The Ansible Core Team
OPTIONS (= is mandatory):
= name
Name of the boolean to configure.
- persistent
Set to `yes' if the boolean setting should survive a reboot.
[Default: no]
type: bool
= state
Desired boolean value
type: bool
NOTES:
* Not tested on any Debian based system.
REQUIREMENTS: libselinux-python, libsemanage-python
AUTHOR: Stephen Fromm (@sfromm)
METADATA:
status:
- stableinterface
supported_by: core
EXAMPLES:
- name: Set httpd_can_network_connect flag on and keep it persistent across reboots
seboolean:
name: httpd_can_network_connect
state: yes
persistent: yes
参数解释
= name
配置 boolean 的名字
- persistent
默认值:no
类型:bool
如果 boolean 设置为开机自启,则设置为yes
= state
设置 boolean 的值