Add a prometheus scrapper for webapp metrics
It was formerly configured on the pergamon's prometheus by https://gitlab.softwareheritage.org/swh/infra/puppet/puppet-swh-site/-/blob/production/site-modules/profile/manifests/swh/deploy/webapp.pp#L218-226
profile::prometheus::export_scrape_config {"swh-webapp_${fqdn}":
job => 'swh-webapp',
target => "${vhost_name}:${vhost_ssl_port}",
scheme => 'https',
metrics_path => '/metrics/prometheus',
labels => {
vhost_name => $vhost_name,
},
}
It can be declared directly in the swh-chart
(detected by the crontab error that generate the status.io save code now counter, which will need to be updated too)
Cron <root@pergamon> chronic sh -c '/usr/local/bin/statusio_export_archive_counters.py -m swh_web_accepted_save_requests --api-id [redacted] --api-key [redacted] --status-page-id [redacted] --metric-id [60adfce46447e9052dccca4b]redacted] -f environment=production -f "load_task_status=~scheduled|not_yet_scheduled" -f instance=moma.internal.softwareheritage.org'
Edited by Vincent Sellier