Blame README-sudocmd.md

Packit Service 0a38ef
Sudocmd module
Packit Service 0a38ef
================
Packit Service 0a38ef
Packit Service 0a38ef
Description
Packit Service 0a38ef
-----------
Packit Service 0a38ef
Packit Service 0a38ef
The sudocmd module allows to ensure presence and absence of sudo command.
Packit Service 0a38ef
Packit Service 0a38ef
The sudocmd module is as compatible as possible to the Ansible upstream `ipa_sudocmd` module.
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Features
Packit Service 0a38ef
--------
Packit Service 0a38ef
* Sudo command management
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Supported FreeIPA Versions
Packit Service 0a38ef
--------------------------
Packit Service 0a38ef
Packit Service 0a38ef
FreeIPA versions 4.4.0 and up are supported by the ipa_sudocmd module.
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Requirements
Packit Service 0a38ef
------------
Packit Service 0a38ef
Packit Service 0a38ef
**Controller**
Packit Service 0a38ef
* Ansible version: 2.8+
Packit Service 0a38ef
Packit Service 0a38ef
**Node**
Packit Service 0a38ef
* Supported FreeIPA version (see above)
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Usage
Packit Service 0a38ef
=====
Packit Service 0a38ef
Packit Service 0a38ef
Example inventory file
Packit Service 0a38ef
Packit Service 0a38ef
```ini
Packit Service 0a38ef
[ipaserver]
Packit Service 0a38ef
ipaserver.test.local
Packit Service 0a38ef
```
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Example playbook to make sure sudocmd exists:
Packit Service 0a38ef
Packit Service 0a38ef
```yaml
Packit Service 0a38ef
---
Packit Service 0a38ef
- name: Playbook to handle sudocmd
Packit Service 0a38ef
  hosts: ipaserver
Packit Service 0a38ef
  become: true
Packit Service 0a38ef
Packit Service 0a38ef
  tasks:
Packit Service 0a38ef
  # Ensure sudocmd is present
Packit Service 0a38ef
  - ipasudocmd:
Packit Service 0a38ef
      ipaadmin_password: SomeADMINpassword
Packit Service 0a38ef
      name: /usr/bin/su
Packit Service 0a38ef
      state: present
Packit Service 0a38ef
```
Packit Service 0a38ef
Packit Service 0a38ef
Example playbook to make sure sudocmd is absent:
Packit Service 0a38ef
Packit Service 0a38ef
```yaml
Packit Service 0a38ef
---
Packit Service 0a38ef
- name: Playbook to handle sudocmd
Packit Service 0a38ef
  hosts: ipaserver
Packit Service 0a38ef
  become: true
Packit Service 0a38ef
Packit Service 0a38ef
  tasks:
Packit Service 0a38ef
  # Ensure sudocmd are absent
Packit Service 0a38ef
  - ipahostgroup:
Packit Service 0a38ef
      ipaadmin_password: SomeADMINpassword
Packit Service 0a38ef
      name: /usr/bin/su
Packit Service 0a38ef
      state: absent
Packit Service 0a38ef
```
Packit Service 0a38ef
Packit Service 0a38ef
Variables
Packit Service 0a38ef
=========
Packit Service 0a38ef
Packit Service 0a38ef
ipasudocmd
Packit Service 0a38ef
-------
Packit Service 0a38ef
Packit Service 0a38ef
Variable | Description | Required
Packit Service 0a38ef
-------- | ----------- | --------
Packit Service 0a38ef
`ipaadmin_principal` | The admin principal is a string and defaults to `admin` | no
Packit Service 0a38ef
`ipaadmin_password` | The admin password is a string and is required if there is no admin ticket available on the node | no
Packit Service 0a38ef
`name` \| `sudocmd` | The sudo command strings. | yes
Packit Service 0a38ef
`description` | The command description string. | no
Packit Service 0a38ef
`nomembers` | Suppress processing of membership attributes. (bool) | no
Packit Service 0a38ef
`state` | The state to ensure. It can be one of `present` or `absent`, default: `present`. | no
Packit Service 0a38ef
Packit Service 0a38ef
Packit Service 0a38ef
Authors
Packit Service 0a38ef
=======
Packit Service 0a38ef
Packit Service 0a38ef
Rafael Guterres Jeffman