Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: configure monitoring #117

Merged
merged 6 commits into from
May 3, 2024
Merged

Conversation

zachariahmiller
Copy link
Contributor

Description

Enabled service and pod monitors in gitlab. For running on k3d-slim-dev in ci/local we dont have to update anything as the gitlab chart checks for the monitoring capabilities presence to deploy the service monitor templates.

Depends on uds-core 0.21.0.

Note: the pepr capability to mutate the service monitors but not pod monitors so we will need to request that feature or PR uds-core to add it. Adding the config for the pod monitor does no break anything.

As this wont get tested in CI in this repo (we should consider the "on-release" test that will exist soon to deploy a full cluster) I will provide visual proof in the comments. This requires no changes to the end user to enable.

Related Issue

Fixes #
116
Relates to #

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Other (security config, docs update, etc)

Checklist before merging

@zachariahmiller zachariahmiller linked an issue May 1, 2024 that may be closed by this pull request
@zachariahmiller
Copy link
Contributor Author

zachariahmiller commented May 1, 2024

image

image

image

image

@zachariahmiller zachariahmiller marked this pull request as draft May 1, 2024 02:01
@zachariahmiller
Copy link
Contributor Author

This is ready for review but just want to throw this out there for discussion...

Example implementation using pepr 5 lines of yaml per monitor:

#monitor:
    - selector:
        app: gitaly
      targetPort: 9236
      portName: http-metrics
      description: Gitaly Metrics

Example implementation using the gitlab charts service monitors:

~5 lines in one file (there is a global disable for monitors and metrics true may be needed i dont recall so maybe more like 2 lines):

  gitaly:
    metrics:
      enabled: true
      serviceMonitor:
        enabled: true

and 8 in another (netpol isnt generated on mutation):

      - direction: Ingress
        remoteNamespace: monitoring
        remoteSelector:
          app: prometheus
        selector:
          app: gitaly
        port: 9236
        description: "Gitaly Service Monitor"

😭

@zachariahmiller zachariahmiller marked this pull request as ready for review May 1, 2024 22:15
@zachariahmiller zachariahmiller merged commit 423687d into main May 3, 2024
10 checks passed
zachariahmiller pushed a commit that referenced this pull request May 7, 2024
🤖 I have created a release *beep* *boop*
---


##
[16.11.1-uds.1](v16.11.1-uds.0...v16.11.1-uds.1)
(2024-05-07)


### Features

* configure monitoring
([#117](#117))
([423687d](423687d))


### Miscellaneous

* add netpol template for runner sandbox
([#125](#125))
([c5ad463](c5ad463))
* **deps:** update gitlab support dependencies
([#114](#114))
([3a3a56b](3a3a56b))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Validate monitoring for GitLab
2 participants