Puppet type and provider for the Pingdom API.
Currently supports the Pingdom 2.1 API.
This module has no external dependencies, and should be widely-compatible and simple to install.
Please consider helping by submitting bug reports. Pull requests also welcome.
pingdom_check
pingdom_user
pingdom_team
[1] pingdom_settings
[1] Multi-user accounts only.
dns
http
httpcustom
imap
ping
pop3
smtp
tcp
udp
Pingdom_team {
account_email => Sensitive($pingdom_account_email),
user_email => Sensitive($pingdom_user_email),
password => Sensitive($pingdom_password),
appkey => $pingdom_appkey
}
Pingdom_user {
account_email => Sensitive($pingdom_account_email),
user_email => Sensitive($pingdom_user_email),
password => Sensitive($pingdom_password),
appkey => $pingdom_appkey
}
Pingdom_check {
account_email => Sensitive($pingdom_account_email),
user_email => Sensitive($pingdom_user_email),
password => Sensitive($pingdom_password),
appkey => $pingdom_appkey,
probe_filters => ['NA']
}
pingdom_user { 'Steve Smith':
ensure => present,
contact_targets => [
{ email => '[email protected]' },
{ number => '555-123-1212', countrycode => '1' }
]
}
pingdom_user { 'DevOps Pager':
ensure => present,
contact_targets => [
{ number => '555-123-1213', countrycode => '1' }
]
}
pingdom_team { 'DevOps':
ensure => present,
users => [
'Steve Smith',
'DevOps Pager'
]
}
pingdom_check { "http://${facts['fqdn']}/check":
ensure => present,
provider => 'http',
host => $facts['fqdn'],
url => '/check',
auth => Sensitive("admin:p@ssw0rd"),
resolution => 5,
requestheaders => {
'Accept' => 'x-application/json'
},
postdata => Sensitive({
'api_key' => 'abcdef1234567890abcdef1234567890',
'api_user' => 'automation'
}),
teams => ['DevOps'],
tags => ['http']
}
pingdom_check { "dns://${facts['fqdn']}":
ensure => present,
provider => 'dns',
host => $facts['fqdn'],
expectedip => '1.2.3.4',
nameserver => '8.8.8.8',
users => ['DevOps Pager'],
tags => ['dns']
}
pingdom_check { "ping://${facts['fqdn']}":
ensure => present,
provider => 'ping',
host => $facts['fqdn'],
tags => ['ping']
}
pingdom_settings { 'Pingdom Settings':
firstname => 'Brad',
lastname => 'Brown',
company => 'Company, Inc.',
email => '[email protected]',
cellphone => '555-123-3333',
description => 'This account is managed by Puppet.'
}
pingdom::account_email: [email protected]
pingdom::user_email: [email protected]
pingdom::password: ENC[PKCS7,EYAMLENCODEDPASSWORD]
pingdom::appkey: ABCDEF1234567890FEDCBA
pingdom::settings:
'Pingdom Settings':
firstname: Brad
lastname: Brown
company: Company, Inc.
email: [email protected]
cellphone: 555-123-3333
description: This account is managed by Puppet.
pingdom::users:
'Steve Smith':
contact_targets:
- email: [email protected]
- number: 555-123-1234
countrycode: 1
'DevOps Pager':
contact_targets:
- number: 555-123-3214
countrycode: 1
pingdom::teams:
'DevOps':
users:
- Steve Smith
- DevOps Pager
pingdom::checks:
"http://%{facts.fqdn}/status":
provider: http
host: "%{facts.fqdn}"
url: /status
teams:
- DevOps
tags:
- http
"ping://%{facts.fqdn}":
provider: ping
host: "%{facts.fqdn}"
users:
- DevOps Pager
tags:
- ping
After configuring Hiera, simply include pingdom
in your manifest:
class myclass {
include pingdom
}
See instructions on PuppetForge.
This module utilizes a feature named autofilter
[default: true
]. Be aware that this feature will automatically tag your checks with a shortened SHA1 hash of the check's name
property, and automatically set filter_tags
to include this tag. This allows us to efficiently locate this check in the future. However, if you have existing checks, enabling autofilter
will cause them to no longer be found (since they lack the requisite SHA1 tag in filter_tags
).
To get around this, and have your existing checks tagged, set autofilter => 'bootstrap'
and run Puppet on all your nodes. This will enable tagging, but not set filter_tags
. If you have a lot of existing checks, this may be a slow Puppet run. Once the run has completed, set autofilter => true
or simply remove the parameter altogether.
puppet resource pingdom_check
command will likely never work, sinceself.instances
is a class method and doesn't have access to instantiation-time parameters such as credentials.- Users API is incomplete (can only manage contacts, not admins).
- There's a difference in login requirements for Starter and Standard plans (specifically, these two levels lack multi-user login). I'm currently only able to test against Enterprise. If you have a Starter or Standard plan and have issues authenticating to Pingdom, reach out to me and we can get it working.
- The Integrations API isn't documented, so we can't manage integrations yet.