You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
894 B
38 lines
894 B
[%
|
|
hostname = ngcp.get_hostname();
|
|
|
|
argv.host = hostname;
|
|
argv.type = 'ha_int';
|
|
PROCESS '/usr/lib/ngcp-ngcpcfg/get_all_shared_ips_for_host';
|
|
ha_ips = out;
|
|
PROCESS '/usr/lib/ngcp-ngcpcfg/get_all_ips_for_host';
|
|
ha_ips = out.merge(ha_ips);
|
|
-%]
|
|
command:
|
|
[% IF monitoring.backend == 'influxdb' || monitoring.influxdb_migrated == 'no' -%]
|
|
|
|
influx -execute 'show databases':
|
|
exit-status: 0
|
|
stdout:
|
|
- "/^name: databases$/"
|
|
- "/^_internal$/"
|
|
- "/^ngcp$/"
|
|
- "/^telegraf$/"
|
|
stderr: []
|
|
timeout: 10000
|
|
[% END -%]
|
|
[% IF monitoring.backend == 'prometheus' -%]
|
|
|
|
promtool query instant http://[% ha_ips.0 || 'localhost' %]:[% prometheus.port || 9090 %] '{__name__=~".+"}':
|
|
exit-status: 0
|
|
stdout:
|
|
- "/^go_/"
|
|
- "/^namedprocess_/"
|
|
- "/^ngcp_/"
|
|
- "/^node_/"
|
|
- "/^process_/"
|
|
- "/^redis_/"
|
|
stderr: []
|
|
timeout: 10000
|
|
[% END -%]
|