Files
dependabot[bot] 203f3fc167 chore(deps): bump helm.sh/helm/v3 from 3.19.4 to 3.19.5 in /examples/sdk/helm-template in the security group (#1963)
chore(deps): bump helm.sh/helm/v3

Bumps the security group in /examples/sdk/helm-template with 1 update: [helm.sh/helm/v3](https://github.com/helm/helm).


Updates `helm.sh/helm/v3` from 3.19.4 to 3.19.5
- [Release notes](https://github.com/helm/helm/releases)
- [Commits](https://github.com/helm/helm/compare/v3.19.4...v3.19.5)

---
updated-dependencies:
- dependency-name: helm.sh/helm/v3
  dependency-version: 3.19.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: security
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-29 11:53:14 -05:00
..

Parse troubleshoot specs from a helm chart

This is an example of using troubleshoot's loader.LoadSpecs API to load specs from rendered manifests in a helm chart. The chart in this example contains a kubernetes Secret & ConfigMap with troubleshoot specs, as well as a troubleshoot custom resource. The custom resource is behind a values flag and does not get rendered by default. The code adds this flag to ensure that the manifest is rendered so as to load it.

The manifests are rendered with the equivalent of helm template --values values.yaml where the output is a YAML multidoc. loader.LoadSpecs will take the YAML multidoc as an input and extract troubleshoot specs inside kuberenetes Secrets and ConfigMaps, and any troubleshoot custom resources found.

This application always uses the local version of troubleshoot so as to build using the latest version of the library. This ensures that the example is kept in sync with new features.

Running

go mod tidy     # sync go modules
go run main.go  # run the application. This should print out a YAML multidoc of the loaded troubleshoot specs