2020-10-16 18:10:34 +00:00
|
|
|
defaults = {
|
|
|
|
'apt': {
|
|
|
|
'packages': {
|
|
|
|
'default-libmysqlclient-dev': {},
|
|
|
|
'libffi-dev': {},
|
|
|
|
'libldap2-dev': {},
|
|
|
|
'libsasl2-dev': {},
|
|
|
|
'libssl-dev': {},
|
|
|
|
'libxml2-dev': {},
|
|
|
|
'libxmlsec1-dev': {},
|
|
|
|
'libxslt1-dev': {},
|
|
|
|
'pkg-config': {},
|
|
|
|
'python3-psycopg2': {},
|
|
|
|
'python3-wheel': {},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'users': {
|
|
|
|
'powerdnsadmin': {
|
|
|
|
'home': '/opt/powerdnsadmin',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'postgresql': {
|
2020-11-10 11:37:58 +00:00
|
|
|
'roles': {
|
2020-10-16 18:10:34 +00:00
|
|
|
'powerdnsadmin': {
|
|
|
|
'password': repo.vault.password_for('{} postgresql powerdnsadmin'.format(node.name)),
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'databases': {
|
|
|
|
'powerdnsadmin': {
|
|
|
|
'owner': 'powerdnsadmin',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
2021-01-29 17:11:17 +00:00
|
|
|
|
|
|
|
|
|
|
|
@metadata_reactor.provides(
|
|
|
|
'icinga2_api/powerdnsadmin/services',
|
|
|
|
)
|
|
|
|
def icinga_check_for_new_release(metadata):
|
|
|
|
return {
|
|
|
|
'icinga2_api': {
|
|
|
|
'powerdnsadmin': {
|
|
|
|
'services': {
|
|
|
|
'POWERDNSADMIN UPDATE': {
|
|
|
|
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_github_for_new_release ngoduykhanh/PowerDNS-Admin {}'.format(metadata.get('powerdnsadmin/version')),
|
|
|
|
'vars.notification.mail': True,
|
|
|
|
'check_interval': '60m',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|