Faidon Liambotis has uploaded a new change for review.
https://gerrit.wikimedia.org/r/281480
Change subject: netops::check: make IPv4 mandatory again
......................................................................
netops::check: make IPv4 mandatory again
Having a appropriately-named monitoring::host is required for the rest
of the monitoring checks, so make IPv4 mandatory again and default
$title to it. The right solution would be to use Icinga's
address/address6 and that's not supported by Puppet's native nagios_host
(and hence neither our very own monitoring::host) :(
Change-Id: Id51b3ac0e8514d91b208b15da86a8b1aa7a623ef
---
M modules/netops/manifests/check.pp
1 file changed, 6 insertions(+), 7 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/80/281480/1
diff --git a/modules/netops/manifests/check.pp
b/modules/netops/manifests/check.pp
index 5c76a6d..2cbf1e6 100644
--- a/modules/netops/manifests/check.pp
+++ b/modules/netops/manifests/check.pp
@@ -8,7 +8,7 @@
# The SNMP community to use to poll the device.
#
# [*ipv4*]
-# The IPv4 address of the device. Optional.
+# The IPv4 address of the device. Required.
#
# [*ipv6*]
# The IPv6 address of the device. Optional.
@@ -28,18 +28,17 @@
define netops::check(
$snmp_community,
- $ipv4=undef,
+ $ipv4,
$ipv6=undef,
$bgp=false,
$interfaces=false,
) {
- if $ipv4 {
- @monitoring::host { "${title} IPv4":
- ip_address => $ipv4,
- group => 'routers',
- }
+ @monitoring::host { $title:
+ ip_address => $ipv4,
+ group => 'routers',
}
+
if $ipv6 {
@monitoring::host { "${title} IPv6":
ip_address => $ipv6,
--
To view, visit https://gerrit.wikimedia.org/r/281480
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id51b3ac0e8514d91b208b15da86a8b1aa7a623ef
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Faidon Liambotis <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits