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

Enabling JMX Monitoring Results in Duplicate Labels #237

Open
trexx opened this issue Aug 8, 2024 · 2 comments
Open

Enabling JMX Monitoring Results in Duplicate Labels #237

trexx opened this issue Aug 8, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@trexx
Copy link

trexx commented Aug 8, 2024

Describe the Bug

A clear and concise description of what the bug is.

The configmap for the JMX configuration contains duplicate labels.

apiVersion: v1
kind: ConfigMap
metadata:
  name: release-name-puppetserver-jmx-config
  labels:
    app.kubernetes.io/component: puppetserver
    app.kubernetes.io/name: puppetserver
    app.kubernetes.io/instance: release-name
    app.kubernetes.io/managed-by: Helm
    helm.sh/chart: puppetserver-9.5.2
    app.kubernetes.io/version: 7.17.0
    app.kubernetes.io/component: puppetserver-compilers
    app.kubernetes.io/name: puppetserver
    app.kubernetes.io/instance: release-name
    app.kubernetes.io/managed-by: Helm
    helm.sh/chart: puppetserver-9.5.2
    app.kubernetes.io/version: 7.17.0

This causes helm / argocd to barf.

Expected Behavior (Behaviour)

No duplicate labels.

Steps to Reproduce

Steps to reproduce the behavior (Behaviour):

  metrics:
    prometheus:
      disableAPICheck: true
      puppetdb:
        enabled: true
      jmx:
        enabled: true

Its likely its unnecessary we have the compiler labels and it maybe possible to have them removed.

@trexx trexx added the bug Something isn't working label Aug 8, 2024
@Xtigyro
Copy link
Contributor

Xtigyro commented Aug 10, 2024

Hey @trexx - this chart is 100% community maintained. Please feel free to send our way a PR if you have the time and energy for helping us.

@davidphay
Copy link
Collaborator

davidphay commented Nov 11, 2024

for information, the issue is generated with both lines:

{{- include "puppetserver.puppetserver.labels" . | nindent 4 }}

{{- include "puppetserver.puppetserver-compilers.labels" . | nindent 4 }}

Both have a reference on {{ include "puppetserver.common.metaLabels" . }} in _helpers.tpl.

Possible solutions (but not tested):

  • you have to to remove 1 include (puppetserver.puppetserver-compilers.labels or puppetserver.puppetserver.labels )
  • Replace and create a new labels template

Based on the other files, I guess the first solution should be used and preserve puppetserver.puppetserver.labels

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants