Fix corrupted splunk-operator-3.0.0.tgz causing Helm test failures#1863
Open
gabrielm-splunk wants to merge 2 commits intodevelopfrom
Open
Fix corrupted splunk-operator-3.0.0.tgz causing Helm test failures#1863gabrielm-splunk wants to merge 2 commits intodevelopfrom
gabrielm-splunk wants to merge 2 commits intodevelopfrom
Conversation
The splunk-operator-3.0.0.tgz file was corrupted - it contained the full
splunk-enterprise chart (4.5MB) instead of just the operator chart (5.8KB).
This caused Helm to load a stale splunk-enterprise as a subchart, leading
to template rendering errors:
Error: INSTALLATION FAILED: template: splunk-enterprise/charts/
splunk-enterprise/templates/enterprise_v4_ingestorcluster.yaml:1:14:
executing "splunk-enterprise/charts/splunk-enterprise/templates/
enterprise_v4_ingestorcluster.yaml" at <.Values.ingestorCluster.enabled>:
nil pointer evaluating interface {}.enabled
Root cause: The file was replaced with a packaged splunk-enterprise chart
in multiple "Restore helm chart version 3.0.0" commits (see b9766dd and
related commits in git history).
Fix:
- Restored correct splunk-operator-3.0.0.tgz from commit a3737ba (5.8KB)
- File now contains only splunk-operator chart content, not splunk-enterprise
Validation:
- helm lint passes on both splunk-operator and splunk-enterprise charts
- helm template successfully renders c3 deployment without errors
- Added tools/validate-helm-charts.sh script to detect future corruption
The validation script checks:
- tgz files start with "splunk-operator/" directory (not "splunk-enterprise/")
- Files don't contain splunk-enterprise/Chart.yaml content
- File sizes are reasonable (detects 4.5MB corruption vs expected 5-400KB)
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
rlieberman-splunk
approved these changes
Apr 21, 2026
Created .github/workflows/validate-helm-charts.yml to automatically validate Helm chart tgz files and prevent corruption. The workflow runs on: - Pull requests that modify helm-chart files (tgz, Chart.yaml, values.yaml) - Pushes to main/develop that touch helm-chart files - Manual trigger via workflow_dispatch Validation checks: 1. Operator chart tgz structure validation (via tools/validate-helm-charts.sh) - Ensures tgz files contain only splunk-operator/ content - Detects embedded splunk-enterprise chart corruption - Verifies file sizes are reasonable 2. Helm lint on both splunk-operator and splunk-enterprise charts 3. Template rendering tests for common deployment patterns: - Default values - C3 deployment (cluster manager + indexer cluster + search head cluster) - S1 deployment (standalone) Benefits: - Catches corrupted tgz files before merge - Validates template syntax and rendering - Provides early feedback on PRs via automated comments - Prevents helm test failures in CI This would have caught the splunk-operator-3.0.0.tgz corruption before it was merged to develop. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
After merging PR #1832 to restore helm support for 3.0.0, helm-tests are failing with:
Root Cause
The
splunk-operator-3.0.0.tgzfile was corrupted - it contained the fullsplunk-enterprisechart package (4.5MB) instead of just thesplunk-operatorchart (5.8KB). This caused Helm to load a stalesplunk-enterpriseas a subchart within the operator chart, leading to nested template path errors.File size comparison:
splunk-operator-3.0.0.tgz= 4.5MB (contains full splunk-enterprise chart)splunk-operator-3.0.0.tgz= 5.8KB (contains only operator chart)splunk-operator-3.1.0.tgz= 6.7KB (correct structure)The corruption happened in multiple "Restore helm chart version 3.0.0 to repository index" commits (b9766dd and related).
Solution
1. Restored correct tgz file
splunk-operatorchart content, not nestedsplunk-enterprise2. Added validation tooling
Created
tools/validate-helm-charts.shto detect future corruption:splunk-operator/directory (notsplunk-enterprise/)splunk-enterprise/Chart.yamlcontent3. Automated CI/CD validation
Created
.github/workflows/validate-helm-charts.ymlthat runs on:The workflow performs:
tools/validate-helm-charts.shon all operator chart tgz filesThis CI check would have caught the corruption before it was merged to develop.
Testing
helm lintpasses on bothsplunk-operatorandsplunk-enterprisechartshelm templatesuccessfully renders c3 deployment without nil pointer errorsVerification Commands
Files Changed
helm-chart/splunk-enterprise/charts/splunk-operator-3.0.0.tgz- Restored correct 5.8KB versiontools/validate-helm-charts.sh- Validation script for detecting tgz corruption.github/workflows/validate-helm-charts.yml- Automated CI/CD validation workflowRelated Issues
Fixes the helm test error reported after PR #1832 merge and adds safeguards to prevent future occurrences.