Skip to content

🏷️ ci: Sync Helm Chart Tags - #13446

Merged
danny-avila merged 2 commits into
devfrom
danny-avila/helm-chart-tag-sync
Jun 1, 2026
Merged

danny-avila merged 2 commits into
devfrom
danny-avila/helm-chart-tag-sync

Conversation

@danny-avila

@danny-avila danny-avila commented Jun 1, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

I added an automated Helm chart tag sync workflow so chart version bumps on main create missing chart-x.y.z tags at the first commit where that version appeared, starting from the existing chart-1.9.0 tag convention.

  • Added a script that scans first-parent main history for helm/librechat/Chart.yaml version changes and creates missing chart-* tags at the corresponding commits.
  • Added an explicit BACKFILL_FROM_VERSION cutoff so the workflow backfills missed tags after the current chart-tag release scheme began without unexpectedly publishing older pre-scheme chart versions.
  • Added a workflow that runs only on pushes to main or manually, fetches main and tags with validated repository inputs, creates missing chart tags, and dispatches the Helm chart release workflow for newly created tags.
  • Added a manual release_existing_tag recovery input to re-dispatch a chart release when a tag exists but the release dispatch needs to be retried.
  • Updated the Helm chart release workflow to accept a validated manual chart_tag, check out the exact tag ref, publish under the repository owner package namespace, and reduce contents permission from write to read.
  • Hardened the privileged workflow path by avoiding PR triggers, validating tag and repository values, using explicit GITHUB_TOKEN permissions, and avoiding third-party actions in the tag-writing workflow.

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • This change requires a documentation update

Testing

  • Ran bash -n .github/scripts/sync-helm-chart-tags.sh.
  • Ran .github/scripts/sync-helm-chart-tags.sh in dry-run mode and confirmed it would create chart-2.0.4 at 830d124e4d and chart-2.0.5 at 566e20b613.
  • Ran RELEASE_EXISTING_TAG=chart-2.0.3 .github/scripts/sync-helm-chart-tags.sh in dry-run mode and confirmed it would dispatch the existing tag recovery path.
  • Parsed .github/workflows/sync-helm-chart-tags.yml and .github/workflows/helmcharts.yml with Ruby YAML loading.
  • Ran git diff --check.
  • Ran a temp bare-repo simulation with PUSH_TAGS=true and confirmed the two expected tags were created and pushed to the simulated remote.
  • Re-ran the temp bare-repo simulation after review fixes and confirmed the existing-tag recovery dry-run path.

Test Configuration:

  • macOS local worktree
  • GitHub CLI 2.92.0
  • Ruby YAML parser from local environment

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • My changes do not introduce new warnings
  • Local unit tests pass with my changes

Copilot AI review requested due to automatic review settings June 1, 2026 12:22

Copy link
Copy Markdown
Collaborator Author

@codex review

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a GitHub Actions automation that backfills and maintains chart-<semver> git tags based on helm/librechat/Chart.yaml version bumps on main, and then triggers the existing Helm chart publishing workflow for any newly-created tags.

Changes:

  • Added a sync-helm-chart-tags workflow that fetches main+tags, creates missing chart-* tags, and dispatches the Helm release workflow.
  • Added a bash script to scan main’s first-parent history for chart version changes and create/push missing chart-* tags.
  • Updated the helmcharts.yml workflow to support manual dispatch with a validated chart_tag, checkout the exact tag ref, and reduce contents permissions to read.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
.github/workflows/sync-helm-chart-tags.yml New workflow to fetch history/tags on main and run the tag-sync script with tag push + release dispatch enabled.
.github/workflows/helmcharts.yml Adds a manual chart_tag input, validates tag format, checks out the tag ref, and reduces contents permission.
.github/scripts/sync-helm-chart-tags.sh New script to detect chart version introduction commits, create missing chart-* tags, push them, and dispatch releases.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/scripts/sync-helm-chart-tags.sh Resolved

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3a6f9c1e43

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .github/scripts/sync-helm-chart-tags.sh Resolved
Comment thread .github/scripts/sync-helm-chart-tags.sh Resolved
Comment thread .github/scripts/sync-helm-chart-tags.sh Resolved

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@danny-avila
danny-avila marked this pull request as ready for review June 1, 2026 12:42
@danny-avila
danny-avila changed the base branch from main to dev June 1, 2026 12:42
@danny-avila
danny-avila merged commit d5a2d3b into dev Jun 1, 2026
@danny-avila
danny-avila deleted the danny-avila/helm-chart-tag-sync branch June 1, 2026 12:43
fuuuzzy pushed a commit to fuuuzzy/LibreChat that referenced this pull request Jun 4, 2026
* ci: Sync Helm chart tags

* ci: Address Helm tag sync review
ThomasVuNguyen pushed a commit to ThomasVuNguyen/LibreChat that referenced this pull request Jul 15, 2026
* ci: Sync Helm chart tags

* ci: Address Helm tag sync review
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants