diff --git a/README.md b/README.md index 3385c97..7bf5146 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,8 @@ Provider: `VirtualBox` The following ports will be forwarded into the Vagrant box: * 80 (guest) => 80 (host) * 443 (guest) => 443 (host) // Webserver with TLS not configured via default -* 5665 (guest) => 5665 (guest) +* 5665 (guest) => 5665 (host) +* 8086 (guest) => 8086 (host) ## Credentials @@ -22,6 +23,7 @@ Default credentials if not customized (Format: `user` - `password`): * IcingaDB-redis password => `redis-pass` * Mysql `*.*` user => `poweruser` - `poweruser` * Mysql root user: `root` - `root0815!` +* InfluxDB admin user: `admin` - `admin12345!` ## Components @@ -33,9 +35,11 @@ The most common used components are pre-installed and configured. * Icingadb Redis * Icinga Web 2 * Icinga Director -* Metrics (Ansible collection `tbauriedel.gographite`) +* Graphite (Ansible collection `tbauriedel.gographite`) * go-carbon * carbonapi +* InfluxDB (Ansible collection `tbauriedel.influxdb2`) + * InfluxDB v2 ## Requirements diff --git a/Vagrantfile b/Vagrantfile index 25d81ed..7f5108d 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -12,4 +12,5 @@ Vagrant.configure("2") do |config| config.vm.network "forwarded_port", guest: 80, host: 80 config.vm.network "forwarded_port", guest: 443, host: 443 config.vm.network "forwarded_port", guest: 5665, host: 5665 + config.vm.network "forwarded_port", guest: 8086, host: 8086 end diff --git a/ansible/playbook.yml b/ansible/playbook.yml index 5f44433..321b830 100644 --- a/ansible/playbook.yml +++ b/ansible/playbook.yml @@ -33,6 +33,8 @@ roles: - tbauriedel.gographite.gocarbon - tbauriedel.gographite.carbonapi + - tbauriedel.influxdb2.repos + - tbauriedel.influxdb2.influxdb2 - geerlingguy.mysql - icinga.icinga.repos - icinga.icinga.icinga2 diff --git a/ansible/vars/icinga2.yml b/ansible/vars/icinga2.yml index f9003f2..1ff90dd 100644 --- a/ansible/vars/icinga2.yml +++ b/ansible/vars/icinga2.yml @@ -31,6 +31,12 @@ icinga2_features: port: 2003 enable_send_thresholds: true enable_send_metadata: true + - name: influxdb2 + host: localhost + port: 8086 + bucket: icinga2 + organization: monitoring + auth_token: "AHDUKAGSszifgj21711sfztGASg2" icinga2_objects: - name: poweruser type: ApiUser diff --git a/ansible/vars/influxdb2.yml b/ansible/vars/influxdb2.yml new file mode 100644 index 0000000..b615bdd --- /dev/null +++ b/ansible/vars/influxdb2.yml @@ -0,0 +1,25 @@ +--- +influxdb_influxdb2_host: "http://localhost:8086" +influxdb_influxdb2_primary_user: + name: admin + password: 'admin12345!' +influxdb_influxdb2_primary_org: default +influxdb_influxdb2_primary_bucket: default +influxdb_influxdb2_retention: 0 +influxdb_influxdb2_admin_token: AHDUKAGSszifgj21711sfztGASg2 + +influxdb_influxdb2_orgs: + - name: monitoring + desc: "Monitoring organization" + token: "{{ influxdb_influxdb2_admin_token }}" + +influxdb_influxdb2_buckets: + - name: icinga2 + org: monitoring + state: present + desc: "Icinga 2 perfdata" + retention: + type: expire + everySeconds: 1209600 # 2 weeks + shardGroupDurationSeconds: 172800 # 2 days + token: "{{ influxdb_influxdb2_admin_token }}" diff --git a/requirements.yml b/requirements.yml index 3cc776f..6930b88 100644 --- a/requirements.yml +++ b/requirements.yml @@ -5,3 +5,4 @@ roles: collections: - name: icinga.icinga - name: tbauriedel.gographite + - name: tbauriedel.influxdb2