update forgejo to 1.20.4

This commit is contained in:
Franzi 2023-09-09 21:09:30 +02:00
parent 40aeeab265
commit 54d55bbb8d
Signed by: kunsi
GPG key ID: 12E3D2136B818350
3 changed files with 20 additions and 4 deletions

View file

@ -37,7 +37,7 @@ files = {
},
'/usr/local/bin/forgejo': {
'content_type': 'download',
'source': node.metadata.get('forgejo/url'),
'source': 'https://codeberg.org/forgejo/forgejo/releases/download/v{0}/forgejo-{0}-linux-amd64'.format(node.metadata.get('forgejo/version')),
'content_hash': node.metadata.get('forgejo/sha1', None),
'mode': '0755',
'triggers': {

View file

@ -26,7 +26,6 @@ defaults = {
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_systemd_unit forgejo',
},
'FORGEJO UPDATE': {
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_forgejo_for_new_release codeberg.org forgejo/forgejo v$(forgejo --version | cut -d" " -f3 | sed "s/\\+/\\-/g")',
'vars.notification.mail': True,
'check_interval': '60m',
},
@ -63,6 +62,23 @@ defaults = {
}
@metadata_reactor.provides(
'icinga2_api/forgejo',
)
def update_monitoring(metadata):
return {
'icinga2_api': {
'forgejo': {
'services': {
'FORGEJO UPDATE': {
'command_on_monitored_host': '/usr/local/share/icinga/plugins/check_forgejo_for_new_release codeberg.org forgejo/forgejo v{}'.format(metadata.get('forgejo/version')),
},
},
},
},
}
@metadata_reactor.provides(
'nginx/vhosts/forgejo',
)

View file

@ -48,8 +48,8 @@ defaultCountryCode = "DE"
jitsi.preferredDomain = "meet.ffmuc.net"
[metadata.forgejo]
url = "https://codeberg.org/forgejo/forgejo/releases/download/v1.20.3-0/forgejo-1.20.3-0-linux-amd64"
sha1 = "3199c656c9b9916f288d5feadcf0b63f6bbe1193"
version = "1.20.4-0"
sha1 = "20994ac3f10a7c6af11743b19bcea33107a49b35"
domain = "git.franzi.business"
enable_git_hooks = true
install_ssh_key = true