ini_file
Collection: community.general
Full Name: parallax.community.general.ini_file
Aliases: community.general.ini_file, ini_file
Synopsis
Manage ini file
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| path | string | yes | Path to the INI-style file | |
| section | string | Section name in INI file. If state is absent without option, the entire section is removed | ||
| option | string | The option name within the section to set or remove | ||
| value | string | The value to set for the option | ||
| state | string | present | Whether the option should be present or absent Choices: present, absent | |
| backup | bool | false | Create a backup file including the timestamp information | |
| no_extra_spaces | bool | false | Do not insert spaces before and after = sign | |
| create | bool | true | If set to true and the file does not exist, the file is created | |
| allow_no_value | bool | false | Allow option without value and without = sign |
Example
- name: Example ini_file task
ini_file:
path: <your_path>