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

fix: Disable Helm test pod when test.enabled=false #15346

Merged
merged 2 commits into from
Dec 10, 2024

Conversation

lindhe
Copy link
Contributor

@lindhe lindhe commented Dec 10, 2024

What this PR does / why we need it:

Before, there was an apparent typo where the Helm test pod was rendered even when test.enabled=false (the test.enabled value didn't really do anything before). This change fixes that.

Which issue(s) this PR fixes:

Replaces #13180

Fixes #12765

Special notes for your reviewer:

Checklist

  • Reviewed the CONTRIBUTING.md guide (required)
  • Documentation added
  • Tests updated
  • Title matches the required conventional commits format, see here
    • Note that Promtail is considered to be feature complete, and future development for logs collection will be in Grafana Alloy. As such, feat PRs are unlikely to be accepted unless a case can be made for the feature actually being a bug fix to existing behavior.
  • Changes that require user attention or interaction to upgrade are documented in docs/sources/setup/upgrade/_index.md
  • If the change is deprecating or removing a configuration option, update the deprecated-config.yaml and deleted-config.yaml files respectively in the tools/deprecated-config-checker directory. Example PR

@lindhe lindhe requested a review from a team as a code owner December 10, 2024 14:46
@CLAassistant
Copy link

CLAassistant commented Dec 10, 2024

CLA assistant check
All committers have signed the CLA.

This comment has been minimized.

Copy link
Contributor

Kubernetes Manifest Diff Summary

Scenario: default-single-binary-values (Added: 0, Modified: 0, Removed: 0)

Summary:

  • Added: 0

  • Modified: 0

  • Removed: 0

Added Files

No added files

Modified Files

No modified files

Removed Files

No removed files

Scenario: default-values (Added: 0, Modified: 0, Removed: 0)

Summary:

  • Added: 0

  • Modified: 0

  • Removed: 0

Added Files

No added files

Modified Files

No modified files

Removed Files

No removed files

Scenario: ingress-values (Added: 0, Modified: 0, Removed: 1)

Summary:

  • Added: 0

  • Modified: 0

  • Removed: 1

Added Files

No added files

Modified Files

No modified files

Removed Files

loki/templates/tests/test-canary.yaml
---
# Source: loki/templates/tests/test-canary.yaml
apiVersion: v1
kind: Pod
metadata:
 name: "loki-helm-test"
 namespace: default
 labels:
 helm.sh/chart: loki-6.23.0
 app.kubernetes.io/name: loki
 app.kubernetes.io/instance: loki-test-chart-name
 app.kubernetes.io/version: "3.3.1"
 app.kubernetes.io/component: helm-test
 annotations:
 "helm.sh/hook": test
spec:
 containers:
 - name: loki-helm-test
 image: docker.io/grafana/loki-helm-test:ewelch-distributed-helm-chart-17db5ee
 env:
 - name: CANARY_SERVICE_ADDRESS
 value: "http://loki-canary:3500/metrics"
 - name: CANARY_PROMETHEUS_ADDRESS
 value: ""
 - name: CANARY_TEST_TIMEOUT
 value: "1m"
 args:
 - -test.v
 restartPolicy: Never

Scenario: legacy-monitoring-values (Added: 0, Modified: 0, Removed: 0)

Summary:

  • Added: 0

  • Modified: 0

  • Removed: 0

Added Files

No added files

Modified Files

No modified files

Removed Files

No removed files

Scenario: simple-scalable-aws-kube-irsa-values (Added: 0, Modified: 0, Removed: 0)

Summary:

  • Added: 0

  • Modified: 0

  • Removed: 0

Added Files

No added files

Modified Files

No modified files

Removed Files

No removed files

Copy link
Collaborator

@trevorwhitney trevorwhitney left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thanks!

@trevorwhitney trevorwhitney merged commit 1fb4e2b into grafana:main Dec 10, 2024
61 checks passed
@lindhe lindhe deleted the lindhe/fix-helm-test branch December 11, 2024 08:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Helm: loki-canary test pod gets rendered even when tests are disabled
3 participants