Repository navigation
helm: namespace k8s resources - #4417
raul-gherman-modaoperandi wants to merge 66 commits into
Conversation
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
DEVOPS-3406 - helm: namespace resouces
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
@raul-gherman-modaoperandi is attempting to deploy a commit to the Different AI Team on Vercel. A member of the Team first needs to authorize it. |
|
@OmarMcAdam Please review the Helm namespace behavior across rendered resources and existing installation/upgrade configuration before merging. Preview deployment checks also need to be resolved or explicitly accounted for. Holding for your review under the current merge instructions. |
Replace implicit secret wiring (secret.create + secret.existingSecret inference) with an explicit secret.secretsMode: inline | existingSecret | externalSecrets, enforced at render time with fail-fast validation for every invalid combination (unknown/emptied mode, missing or blank existingSecret, secretStoreRef.name, or pathPrefix, wrong create/ existingSecret per mode, invalid store kind). externalSecrets mode renders an ExternalSecret (ESO) whose spec.data is generated from secret.keys against <pathPrefix>/<KEY_NAME>, so the pulled key list can never drift from what workloads consume, and no secret material lands in git or rendered manifests — the GitOps/ArgoCD-safe path. apiVersion is selected from cluster capabilities (v1 else v1beta1) and target.deletionPolicy defaults to Retain. Also stop the migration Job from inlining DATABASE_URL and DEN_DB_ENCRYPTION_KEY as plaintext env outside inline mode; it now uses secretKeyRef for existingSecret/externalSecrets flows. Documented in README (per-mode subsections) and values.yaml REQUIRED comments; covered by tests/external-secrets.sh (render assertions for all three modes plus 12 negative validation cases).
…esource in Helm chart
…esource in Helm chart
…RBAC, init containers, and hook annotations
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
DEVOPS-3406 - helm: declared secretsMode with ESO ExternalSecret support
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
Co-authored-by: raul-gherman-modaoperandi <68240333+raul-gherman-modaoperandi@users.noreply.github.com>
DEVOPS-3406 - Update hook-delete-policy for migration Job and RBAC to prevent sync issues
…Ps for web and API services
DEVOPS-3406 - add separate ingress templates for API and web services
| # hosts, so it is safe to reuse here. The reserved static IP is NOT — GKE | ||
| # gives each Ingress its own GCLB, so two Ingresses referencing the same | ||
| # global-static-ip-name would fight over one forwarding rule and only one | ||
| # would reconcile. Each host therefore gets its own reserved IP below. |
Contributor screen: needs maintainer reviewCommit Database changes need a human review (schema, migrations or migration jobs):
Nothing else runs yet. A maintainer reviews the changes, including the items above, then comments |
|
Thanks for this. The PR has grown well past namespacing (ExternalSecrets, ingress split, RBAC, GCP docs), and the default |
Summary
namespacevalue (defaultopenwork) to theopenwork-eeHelm chart and setsmetadata.namespacefrom it on all 11 namespaced resources: ConfigMap, Secret, Ingress, migration Job, env-probe test Job, and the den-api / den-web / inference Services and Deployments.openwork-ee.namespacehelper intemplates/_helpers.tplthat falls back to.Release.Namespacewhen the value is cleared.README.md(new "Namespace" section), surfaces the rendered namespace intemplates/NOTES.txt, and adds atests/namespace.shchart check.Why
metadata.namespace, sohelm template ... | kubectl apply -f -pipelines fell back to the kubectl context namespace — the migration Job landed inkube-system.Issue
Scope
packaging/helm/openwork-ee/values.yaml: new documentednamespace: openworkvalue.packaging/helm/openwork-ee/templates/_helpers.tpl: newopenwork-ee.namespacehelper.metadata.namespaceadded inconfigmap.yaml,secret.yaml,migration-job.yaml,ingress.yaml,den-api.yaml(Service + Deployment),den-web.yaml(Service + Deployment),inference.yaml(Service + Deployment),tests/env-probe-job.yaml.templates/NOTES.txt: prints the resolved namespace after install.README.md: new "Namespace" section documenting the value,--namespacealignment forhelm install, and the need to pre-create the namespace inhelm template | kubectl applyflows.tests/namespace.sh: new render-assertion chart check.Out of scope
packaging/helm/openwork-ee/tests/*.share the established proof pattern for this chart (no journey spec covers chart rendering).packaging/helm/openwork-ee/examples/.Testing
Ran
for test in packaging/helm/openwork-ee/tests/*.sh; do bash "$test"; done(with helm v3.16.3 on PATH)helm template openwork-ee packaging/helm/openwork-ee(+ variants:--set ingress.enabled=true --set inference.enabled=true,--set namespace=platform,--set namespace=,--namespace rel-ns) to inspect renderednamespace:fieldsResult
namespace chart checks passed(default render puts all 8 default resources / 11 with ingress+inference inopenwork; override wins everywhere; cleared value falls back to the release namespace).CI status
publish-ee-imagesworkflow chart checks on push)Manual verification
helm template openwork-ee ./packaging/helm/openwork-eeand confirm every manifest hasmetadata.namespace: openwork(including the migration Job).helm template openwork-ee ./packaging/helm/openwork-ee --set namespace=platformand confirm all manifests useplatform.helm template openwork-ee ./packaging/helm/openwork-ee --set namespace= --namespace rel-nsand confirm all manifests fall back torel-ns.Evidence
Risk
metadata.namespaceis declarative and matches the documented--namespace openworkinstall flow. Values-compatibility risk is minimal — existing releases installed with--namespace openwork(per README) render identical effective namespaces; only pipelines that relied on an implicit context namespace different fromopenworkmust now setnamespaceexplicitly.Rollback