[PR #687] [MERGED] fix: create backend service account before migrations run #686

Closed
opened 2026-06-05 19:17:25 -04:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/langchain-ai/helm/pull/687
Author: @langchain-infra
Created: 4/20/2026
Status: Merged
Merged: 4/20/2026
Merged by: @langchain-infra

Base: mainHead: fix/migration-sa-sync-wave


📝 Commits (2)

  • 396fa0e fix: create backend service account before migrations run
  • fc74a9b fix: sync top-level config-map and secret before migrations

📊 Changes

4 files changed (+4 additions, -1 deletions)

View changed files

📝 charts/langsmith/Chart.yaml (+1 -1)
📝 charts/langsmith/templates/backend/service-account.yaml (+1 -0)
📝 charts/langsmith/templates/config-map.yaml (+1 -0)
📝 charts/langsmith/templates/secrets.yaml (+1 -0)

📄 Description

Summary

  • Backend migration jobs (postgres-migrations, clickhouse-migrations) run as ArgoCD Sync hooks at sync-wave -1 and reference backend.serviceAccountName, but the backend ServiceAccount had no sync-wave annotation (defaulted to 0). ArgoCD therefore tried to run the migration hooks before the SA existed.
  • Annotate charts/langsmith/templates/backend/service-account.yaml with argocd.argoproj.io/sync-wave: "-2" so it is created ahead of the migrations (matching the pattern already used by the postgres/redis/clickhouse SAs).
  • Bump chart version 0.14.00.14.1.

Test plan

  • helm template the chart and verify the backend SA renders with argocd.argoproj.io/sync-wave: "-2".
  • Deploy via ArgoCD against a test cluster and confirm the migration hooks run successfully on a fresh install (SA exists before the hook fires).
  • Confirm no regression on upgrade path — migration hook still runs pre-upgrade as before.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/langchain-ai/helm/pull/687 **Author:** [@langchain-infra](https://github.com/langchain-infra) **Created:** 4/20/2026 **Status:** ✅ Merged **Merged:** 4/20/2026 **Merged by:** [@langchain-infra](https://github.com/langchain-infra) **Base:** `main` ← **Head:** `fix/migration-sa-sync-wave` --- ### 📝 Commits (2) - [`396fa0e`](https://github.com/langchain-ai/helm/commit/396fa0e56bde575cc1f2be6dc9a810479dee39b2) fix: create backend service account before migrations run - [`fc74a9b`](https://github.com/langchain-ai/helm/commit/fc74a9bd3b87bbb71de36e6aaa6ab3b2e92e2661) fix: sync top-level config-map and secret before migrations ### 📊 Changes **4 files changed** (+4 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `charts/langsmith/Chart.yaml` (+1 -1) 📝 `charts/langsmith/templates/backend/service-account.yaml` (+1 -0) 📝 `charts/langsmith/templates/config-map.yaml` (+1 -0) 📝 `charts/langsmith/templates/secrets.yaml` (+1 -0) </details> ### 📄 Description ## Summary - Backend migration jobs (`postgres-migrations`, `clickhouse-migrations`) run as ArgoCD `Sync` hooks at sync-wave `-1` and reference `backend.serviceAccountName`, but the backend ServiceAccount had no sync-wave annotation (defaulted to `0`). ArgoCD therefore tried to run the migration hooks before the SA existed. - Annotate `charts/langsmith/templates/backend/service-account.yaml` with `argocd.argoproj.io/sync-wave: "-2"` so it is created ahead of the migrations (matching the pattern already used by the postgres/redis/clickhouse SAs). - Bump chart `version` `0.14.0` → `0.14.1`. ## Test plan - [x] `helm template` the chart and verify the backend SA renders with `argocd.argoproj.io/sync-wave: "-2"`. - [x] Deploy via ArgoCD against a test cluster and confirm the migration hooks run successfully on a fresh install (SA exists before the hook fires). - [x] Confirm no regression on upgrade path — migration hook still runs `pre-upgrade` as before. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-06-05 19:17:25 -04:00
yindo closed this issue 2026-06-05 19:17:25 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/helm#686