Default variable details
Some of debops.influxdb default variables have more extensive configuration
than simple strings or lists, here you can find documentation and examples for
them.
influxdb__databases
List of databases that should be present or absent on a given InfluxDB server. Each database is defined as a YAML dict with the following keys:
databaseornameRequired. Name of the database. Names of databases can contain any unicode character
stateOptional. If value is
present, the database will be created; ifabsent, the database will be removed. It is defaulted topresent.proxiesOptional. Defaults to
{{ omit }}. Dict of HTTP(S) proxy to use for Requests to connect to InfluxDB server. Overridesinfluxdb__proxies.validate_certsOptional, boolean. Defaults to
True. If set toFalse, the SSL certificates will not be validated. This should only set to no used on personally controlled sites using self-signed certificates. Overridesinfluxdb__validate_certs.
Examples
Create databases, remove some of the existing ones:
influxdb__databases:
- name: 'dbname'
influxdb__retention_policies
List of retention policies that should be present on a given InfluxDB server database. Each retention policy is defined as a YAML dict with the following keys:
policyornameRequired. Name of the retention policy.
databaseRequired. Name of the database. Names of databases can contain any unicode character
durationRequired. Determines how long InfluxDB keeps the data. The
durationis a duration literal orINF(infinite). The minimum duration for a retention policy is one hour and the maximum duration is INF.replicationRequired. Determines how many independent copies of each point are stored in the cluster. If the replication factor is set to 2, each series is stored on 2 separate nodes. If the replication factor is equal to the number of data nodes, data is replicated on each node in the cluster.
defaultOptional. Defaults to
False. Sets the new retention policy as the default retention policy for the database.proxiesOptional. Defaults to
{{ omit }}. Dict of HTTP(S) proxy to use for Requests to connect to InfluxDB server. Overridesinfluxdb__proxies.validate_certsOptional, boolean. Defaults to
True. If set toFalse, the SSL certificates will not be validated. This should only set to no used on personally controlled sites using self-signed certificates. Overridesinfluxdb__validate_certs.
Examples
Create retention policies:
influxdb__retention_policies:
- name: 'fourweeks'
database: 'dbname'
duration: '4w'
replication: 1
default: True
influxdb__users
List of user accounts that should be present or absent on a given InfluxdDB server. Each user account is defined as a dict with a set of keys and values.
User account parameters
userornameRequired. Name of the user.
passwordOptional. If specified, the role will set it as the password for the InfluxDB account. If not present, a random password will be generated automatically and stored in the
secret/directory on the Ansible Controller. Refer to the debops.secret role for more details.grantsOptional. Privileges to grant to this user. Takes a list of dicts containing the
databaseandprivilegekeys. If this argument is not provided, the current grants will be left alone. If an empty list is provided, all grants for the user will be removed. It is added in Ansible 2.8.adminOptional. Whether the user should be in the admin role or not. Since Ansible 2.8, the role will also be updated. It is defaulted to
no.stateOptional. If value is
present, the database will be created; ifabsent, the database will be removed. It is defaulted topresent.proxiesOptional. Defaults to
{{ omit }}. Dict of HTTP(S) proxy to use for Requests to connect to InfluxDB server. Overridesinfluxdb__proxies.validate_certsOptional, boolean. Defaults to
True. If set toFalse, the SSL certificates will not be validated. This should only set to no used on personally controlled sites using self-signed certificates. Overridesinfluxdb__validate_certs.
Examples
Create an user
influxdb__users:
- name: 'someuser'
grants:
- database: 'dbname'
privilege: 'READ'