2020-09-06 10:05:42 +00:00
|
|
|
defaults = {
|
2020-11-07 08:39:57 +00:00
|
|
|
'apt': {
|
|
|
|
'packages': {
|
|
|
|
'ffmpeg': {},
|
|
|
|
},
|
|
|
|
},
|
2020-11-21 17:55:06 +00:00
|
|
|
'icinga2_api': {
|
|
|
|
'mautrix-telegram': {
|
|
|
|
'services': {
|
|
|
|
'MAUTRIX-TELEGRAM PROCESS': {
|
|
|
|
'command_on_monitored_host': '/usr/lib/nagios/plugins/check_procs -a mautrix-telegram -c 1:',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2020-09-06 10:05:42 +00:00
|
|
|
'matrix-synapse': {
|
|
|
|
'appservice_configs': {
|
|
|
|
'/opt/mautrix-telegram/registration.yaml',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'mautrix-telegram': {
|
|
|
|
'database': {
|
|
|
|
'user': 'mautrix-telegram',
|
|
|
|
'password': repo.vault.password_for('{} postgresql mautrix-telegram'.format(node.name)),
|
|
|
|
'database': 'mautrix-telegram',
|
|
|
|
},
|
2020-09-12 10:59:34 +00:00
|
|
|
'as_token': repo.vault.password_for('{} mautrix-telegram as_token'.format(node.name)),
|
|
|
|
'hs_token': repo.vault.password_for('{} mautrix-telegram hs_token'.format(node.name)),
|
|
|
|
'sender_localpart': repo.vault.password_for('{} mautrix-telegram sender_localpart'.format(node.name)),
|
2020-09-06 10:05:42 +00:00
|
|
|
},
|
|
|
|
'postgresql': {
|
2020-11-10 11:37:58 +00:00
|
|
|
'roles': {
|
2020-09-06 10:05:42 +00:00
|
|
|
'mautrix-telegram': {
|
|
|
|
'password': repo.vault.password_for('{} postgresql mautrix-telegram'.format(node.name)),
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'databases': {
|
|
|
|
'mautrix-telegram': {
|
|
|
|
'owner': 'mautrix-telegram',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2021-07-17 08:17:39 +00:00
|
|
|
'zfs': {
|
|
|
|
'datasets': {
|
|
|
|
'tank/mautrix-telegram': {
|
|
|
|
'mountpoint': '/opt/mautrix-telegram',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2020-09-06 10:05:42 +00:00
|
|
|
}
|
|
|
|
|
2020-11-21 19:35:51 +00:00
|
|
|
|
2021-01-07 17:44:38 +00:00
|
|
|
@metadata_reactor.provides(
|
|
|
|
'icinga2_api/mautrix-telegram/services',
|
|
|
|
)
|
2020-11-21 19:35:51 +00:00
|
|
|
def icinga_check_for_new_release(metadata):
|
|
|
|
return {
|
|
|
|
'icinga2_api': {
|
|
|
|
'mautrix-telegram': {
|
|
|
|
'services': {
|
|
|
|
'MAUTRIX-TELEGRAM UPDATE': {
|
|
|
|
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_github_for_new_release tulir/mautrix-telegram {}'.format(metadata.get('mautrix-telegram/version')),
|
2020-12-05 08:17:21 +00:00
|
|
|
'vars.notification.mail': True,
|
2020-11-22 10:38:53 +00:00
|
|
|
'check_interval': '60m',
|
2020-11-21 19:35:51 +00:00
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|