2021-01-16 21:03:38 +00:00
|
|
|
defaults = {
|
|
|
|
'apt': {
|
|
|
|
'packages': {
|
|
|
|
'gettext': {},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'backups': {
|
|
|
|
'paths': {
|
|
|
|
'/opt/pretalx/data',
|
|
|
|
},
|
|
|
|
},
|
2021-04-02 12:59:56 +00:00
|
|
|
'bash_aliases': {
|
|
|
|
'pretalx': 'sudo /opt/pretalx/venv/bin/python -m pretalx',
|
|
|
|
},
|
2021-01-16 21:03:38 +00:00
|
|
|
'icinga2_api': {
|
2021-01-16 21:12:16 +00:00
|
|
|
'pretalx': {
|
2021-01-16 21:03:38 +00:00
|
|
|
'services': {
|
|
|
|
'PRETALX-WEB PROCESS': {
|
|
|
|
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_systemd_unit pretalx-web',
|
|
|
|
},
|
|
|
|
'PRETALX-WORKER PROCESS': {
|
|
|
|
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_systemd_unit pretalx-worker',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'pretalx': {
|
|
|
|
'database': {
|
|
|
|
'user': 'pretalx',
|
|
|
|
'password': repo.vault.password_for('{} postgresql pretalx'.format(node.name)),
|
|
|
|
'database': 'pretalx',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'postgresql': {
|
|
|
|
'roles': {
|
|
|
|
'pretalx': {
|
|
|
|
'password': repo.vault.password_for('{} postgresql pretalx'.format(node.name)),
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'databases': {
|
|
|
|
'pretalx': {
|
|
|
|
'owner': 'pretalx',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@metadata_reactor.provides(
|
|
|
|
'icinga2_api/pretalx/services',
|
|
|
|
)
|
|
|
|
def icinga_check_for_new_release(metadata):
|
|
|
|
return {
|
|
|
|
'icinga2_api': {
|
|
|
|
'pretalx': {
|
|
|
|
'services': {
|
|
|
|
'PRETALX UPDATE': {
|
|
|
|
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_github_for_new_release pretalx/pretalx {}'.format(metadata.get('pretalx/version')),
|
|
|
|
'vars.notification.mail': True,
|
|
|
|
'check_interval': '60m',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|