Add NRPE checks for services

Adds the nrpe-external-master layer and checks for services managed by
this charm.

func-test-pr: https://github.com/openstack-charmers/zaza-openstack-tests/pull/433
Layer PR: https://github.com/openstack-charmers/charm-layer-ovn/pull/23

Change-Id: I69dd7238fab1b7dee4e39ddb49ea40b84bf850cf
Closes-Bug: #1896674
This commit is contained in:
Xav Paice 2020-09-28 18:01:19 +13:00
parent 1bb00bb188
commit 5b33ef3cf7
9 changed files with 50 additions and 7 deletions

View File

@ -1 +1,15 @@
options: {}
options:
nagios_context:
default: "juju"
type: string
description: |
A string that will be prepended to instance name to set the host name
in nagios. So for instance the hostname would be something like:
juju-myservice-0
If you're running multiple environments with the same services in them
this allows you to differentiate between them.
nagios_servicegroups:
default: ""
type: string
description: |
Comma separated list of nagios servicegroups for the service checks.

View File

@ -1,6 +1,7 @@
includes:
- layer:ovn
- interface:ovsdb
- interface:nrpe-external-master
options:
basic:
use_venv: True

View File

@ -16,3 +16,7 @@ extra-bindings:
requires:
ovsdb:
interface: ovsdb
provides:
nrpe-external-master:
interface: nrpe-external-master
scope: container

View File

@ -8,6 +8,8 @@ relations:
- ovn-central:ovsdb
- - ovn-dedicated-chassis:certificates
- vault:certificates
- - ovn-dedicated-chassis:nrpe-external-master
- nrpe:nrpe-external-master
applications:
mysql:
charm: cs:~openstack-charmers-next/percona-cluster
@ -21,7 +23,9 @@ applications:
options:
source: cloud:bionic-train
ovn-dedicated-chassis:
charm: cs:~openstack-charmers-next/ovn-dedicated-chassis
charm: ../../../ovn-dedicated-chassis
num_units: 2
options:
source: cloud:bionic-train
nrpe:
charm: cs:nrpe

View File

@ -8,6 +8,8 @@ relations:
- ovn-central:ovsdb
- - ovn-dedicated-chassis:certificates
- vault:certificates
- - ovn-dedicated-chassis:nrpe-external-master
- nrpe:nrpe-external-master
applications:
mysql:
charm: cs:~openstack-charmers-next/percona-cluster
@ -21,7 +23,9 @@ applications:
options:
source: cloud:bionic-ussuri/proposed
ovn-dedicated-chassis:
charm: cs:~openstack-charmers-next/ovn-dedicated-chassis
charm: ../../../ovn-dedicated-chassis
num_units: 2
options:
source: cloud:bionic-ussuri
nrpe:
charm: cs:nrpe

View File

@ -40,6 +40,9 @@ applications:
to:
- '3'
nrpe:
charm: cs:nrpe
ovn-central:
charm: cs:~openstack-charmers-next/ovn-central
num_units: 3
@ -50,9 +53,8 @@ applications:
- '5'
- '6'
ovn-dedicated-chassis:
charm: cs:~openstack-charmers-next/ovn-dedicated-chassis
charm: ../../../ovn-dedicated-chassis
num_units: 2
options:
source: *openstack-origin
@ -72,3 +74,5 @@ relations:
- 'ovn-central:ovsdb'
- - 'ovn-dedicated-chassis:certificates'
- 'vault:certificates'
- - 'ovn-dedicated-chassis:nrpe-external-master'
- 'nrpe:nrpe-external-master'

View File

@ -50,6 +50,8 @@ applications:
- '5'
- '6'
nrpe:
charm: cs:nrpe
ovn-dedicated-chassis:
charm: cs:~openstack-charmers-next/ovn-dedicated-chassis
@ -72,3 +74,5 @@ relations:
- 'ovn-central:ovsdb'
- - 'ovn-dedicated-chassis:certificates'
- 'vault:certificates'
- - 'ovn-dedicated-chassis:nrpe-external-master'
- 'nrpe:nrpe-external-master'

View File

@ -39,6 +39,9 @@ applications:
num_units: 1
to:
- '3'
nrpe:
charm: cs:nrpe
ovn-central:
charm: cs:~openstack-charmers-next/ovn-central
@ -50,9 +53,8 @@ applications:
- '5'
- '6'
ovn-dedicated-chassis:
charm: cs:~openstack-charmers-next/ovn-dedicated-chassis
charm: ../../../ovn-dedicated-chassis
num_units: 2
options:
source: *openstack-origin
@ -60,6 +62,7 @@ applications:
- '7'
- '8'
relations:
- - 'vault-mysql-router:db-router'
@ -72,3 +75,5 @@ relations:
- 'ovn-central:ovsdb'
- - 'ovn-dedicated-chassis:certificates'
- 'vault:certificates'
- - 'ovn-dedicated-chassis:nrpe-external-master'
- 'nrpe:nrpe-external-master'

View File

@ -18,6 +18,9 @@ target_deploy_status:
vault:
workload-status: blocked
workload-status-message: Vault needs to be initialized
nrpe:
workload-status: blocked
workload-status-message: "Nagios server not configured or related"
configure:
- zaza.openstack.charm_tests.vault.setup.auto_initialize_no_validation
tests: