rockandska.influxdb

ansible-role-influxdb

=========

This is an Ansible role to install and configure InfluxDB using InfluxDB binaries.
You can find it on Ansible Galaxy.

Ansible Galaxy:
Galaxy Score

Travis Build:
Build Status

Requirements on Remote Hosts


For all distributions

  • logrotate
  • python requests version 1.0.0 or higher (needed for user, database, and retention policies management)
  • python influxdb version 0.9.0 or higher (needed for user, database, and retention policies management)

For Debian / Ubuntu

  • apt-transport-https
  • gpg-agent
  • ca-certificates

For CentOS / RedHat

  • gnupg2

Role Variables


Default variables are in defaults/main.yml

---
###########
# Install #
###########
influxdb_version: 1.7.4

influxdb_rpm_url: "https://dl.influxdata.com/influxdb/releases/influxdb-{{ influxdb_version }}.x86_64.rpm"
influxdb_rpm_sha256: "93caa49159e76b3338abc191c85d46d134ac67697a0c7f874c937baa38dd6a5e"
influxdb_rpm_dest_path: "/usr/src"

influxdb_deb_url: "https://dl.influxdata.com/influxdb/releases/influxdb_{{ influxdb_version }}_amd64.deb"
influxdb_deb_sha256: "5488bd8889de7d45aa09cdccc845156e2d59442871ad6899d64d797e42f2888b"
influxdb_deb_dest_path: "/usr/src"

#################
# Custom Config #
#################
influxdb_vars_files: []

influxdb_config_tpl: etc/influxdb/influxdb.conf.j2
influxdb_config: {}

influxdb_systemd_override_tpl: etc/systemd/system/influxdb.service.d/override.conf.j2
influxdb_systemd_override: {}

influxdb_custom_logrotate_tpl: etc/logrotate.d/influxdb.j2
influxdb_custom_logrotate:

############
# Api user #
############
influxdb_management_hostname:
influxdb_management_port:
influxdb_management_validate_certs:
influxdb_management_proxies:
influxdb_management_login_username:
influxdb_management_login_password:
influxdb_management_retries:
influxdb_management_ssl:
influxdb_management_timeout:
influxdb_management_udp_port:
influxdb_management_use_udp:

#########
# Users #
#########
influxdb_users_to_create: []
influxdb_users_to_delete: []

#############
# Databases #
#############
influxdb_databases_to_create: []
influxdb_databases_to_delete: []

############
# Policies #
############
influxdb_retention_policies_to_create: []

#########
# Debug #
#########
influxdb_hide_log: true

Variable Details

  • influxdb_version: Specify which InfluxDB version to install from here.
  • influxdb_rpm_url: URL for the RPM package of InfluxDB.
  • influxdb_rpm_sha256: SHA256 checksum for the RPM package for integrity check.
  • influxdb_rpm_dest_path: Where to download the RPM package.
  • influxdb_deb_url: URL for the DEB package of InfluxDB.
  • influxdb_deb_sha256: SHA256 checksum for the DEB package for integrity check.
  • influxdb_deb_dest_path: Where to download the DEB package.
  • influxdb_vars_files: List of variable files to override defaults if needed.
  • influxdb_config_tpl: Path to the InfluxDB config template.
  • influxdb_config: Custom configuration settings for InfluxDB.

For further variable details and how to set them up, please check the original document.

Example Playbook


- hosts: influxdb
  roles:
    - rockandska.influxdb

Local Testing


Use Docker with molecule (version 2.x) for local testing. Make sure to have Docker installed on your system.

Install tox for managing testing across various Ansible versions:

$ sudo pip install tox
# or
$ pip install --user tox

To test all Ansible versions (this might take some time):

$ tox

To run a specific model command on a specific environment with the default test scenario:

$ tox -e py27-ansible25 -- molecule test -s default

For more info about Molecule, refer to their documentation.

If you want to run tests on a remote Docker host, set the DOCKER_HOST variable before running the tests.

License


BSD

Informazioni sul progetto

InfluxDB installation / configuration

Installa
ansible-galaxy install rockandska.influxdb
Licenza
Unknown
Download
124
Proprietario