community.general.influxdb_database – Manage InfluxDB databases¶
Note
This plugin is part of the community.general collection (version 1.3.6).
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.influxdb_database
.
Requirements¶
The below requirements are needed on the host that executes this module.
python >= 2.6
influxdb >= 0.9
requests
Parameters¶
Examples¶
# Example influxdb_database command from Ansible Playbooks
- name: Create database
community.general.influxdb_database:
hostname: "{{influxdb_ip_address}}"
database_name: "{{influxdb_database_name}}"
- name: Destroy database
community.general.influxdb_database:
hostname: "{{influxdb_ip_address}}"
database_name: "{{influxdb_database_name}}"
state: absent
- name: Create database using custom credentials
community.general.influxdb_database:
hostname: "{{influxdb_ip_address}}"
username: "{{influxdb_username}}"
password: "{{influxdb_password}}"
database_name: "{{influxdb_database_name}}"
ssl: yes
validate_certs: yes
Authors¶
Kamil Szczygiel (@kamsz)