Skip to content

Commit 833eb9d

Browse files
authored
Merge pull request #10348 from solo-io/sheidkamp/cherry-pick-helm-doc-gen
Fix published Helm docs from main branch
2 parents 8a38144 + 9dcfad9 commit 833eb9d

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
changelog:
2+
- type: NON_USER_FACING
3+
issueLink: https://github.com/solo-io/solo-projects/issues/6888
4+
resolvesIssue: false
5+
description: >-
6+
Update helm public docs generation to work from main branch and only pull in released changes

docs/cmd/generate_docs.go

+3-5
Original file line numberDiff line numberDiff line change
@@ -454,11 +454,9 @@ func fetchEnterpriseHelmValues(_ []string) error {
454454
if err != nil {
455455
return err
456456
}
457-
version, err := semver.NewVersion(string(semverReleaseTag))
458-
if err != nil {
459-
return err
460-
}
461-
minorReleaseTag := fmt.Sprintf("v%d.%d.x", version.Major(), version.Minor())
457+
458+
minorReleaseTag := "v" + string(semverReleaseTag)
459+
462460
files, err := githubutils.GetFilesFromGit(ctx, client, repoOwner, glooEnterpriseRepo, minorReleaseTag, path)
463461
if err != nil {
464462
return err

pkg/github-action-utils/version.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ func GetLatestEnterpriseVersion(repoRootPath string, repo string, owner string)
3535
return err
3636
}
3737
defer f.Close()
38-
enterpriseVersion, err := version.GetLatestHelmChartVersionWithMaxVersion(version.EnterpriseHelmRepoIndex, version.GlooEE, true, maxGlooEVersion)
38+
// get the latest version from the helm repo, include unstable versions so it works from the main branches
39+
// for LTS branches, unstable versions will be filtered out by the version constraints
40+
enterpriseVersion, err := version.GetLatestHelmChartVersionWithMaxVersion(version.EnterpriseHelmRepoIndex, version.GlooEE, false, maxGlooEVersion)
3941
if err != nil {
4042
return err
4143
}

0 commit comments

Comments
 (0)