Allow enabling sidekiq_exporter logs
What does this MR do?
Allow enabling sidekiq_exporter
logs.
Sidekiq runs a metrics exporter process that serves Prometheus scrapes. This is a server process that emits its own logs.
These logs are disabled by default in the Rails app but can be enabled via the log_enabled switch.
This change makes this configurable in the Chart.
Related issues
gitlab-org/gitlab-metrics-exporter#19 (closed)
Test plan
- Check out this branch.
- Run:
$ helm upgrade gitlab . \ --set gitlab.sidekiq.metrics.log_enabled=true
- SSH into
sidekiq
pod and check that the log file exists:git@gitlab-sidekiq-all-in-1-v2-7d7c6bcdfd-kvjrz:/$ tail /var/log/gitlab/sidekiq_exporter.log [2022-09-19T14:24:07.237+0000] INFO WEBrick 1.6.1 [2022-09-19T14:24:07.237+0000] INFO ruby 2.7.5 (2021-11-24) [x86_64-linux] [2022-09-19T14:24:07.257+0000] INFO WEBrick::HTTPServer#start: pid=23 port=3807 [2022-09-19T14:24:38.487+0000] 10.12.1.19 - - [19/Sep/2022:14:24:38 UTC] "GET /metrics HTTP/1.1" 200 881 "-" "Prometheus/2.31.1"
Checklist
See Definition of done.
For anything in this list which will not be completed, please provide a reason in the MR discussion.
Required
-
Merge Request Title and Description are up to date, accurate, and descriptive -
MR targeting the appropriate branch -
MR has a green pipeline on GitLab.com
Expected (please provide an explanation if not completing)
-
Test plan indicating conditions for success has been posted and passes -
Documentation created/updated -
Tests added -
Integration tests added to GitLab QA -
Equivalent MR/issue for omnibus-gitlab opened. Not necessary since Omnibus already supports that.
Edited by Mitchell Nielsen