Fix NeMo Microservices Installation Issues and Add Helm Hooks#22
Open
Fix NeMo Microservices Installation Issues and Add Helm Hooks#22
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixes critical installation issues in the NeMo Microservices deployment and adds automated Helm hooks to replace manual bash script operations, enabling a cleaner declarative installation process.
Problems Solved
Problem: NemoEvaluator pods fail with
Init:CrashLoopBackOffdue to the missingEVALUATOR_IMAGEenvironment variable in theevaluator-db-migrationinit containerRoot Cause: NIM Operator v3.0.2 bug - fails to propagate
EVALUATOR_IMAGEfrom NemoEvaluator CRD to deployment init containersSolution: Added Helm post-install hook that patches the evaluator deployment to add the missing env var
Problem: Evaluator cannot connect to NIM models - default port changed from 8000 to 80
Root Cause: Recent changes defaulted to port 80 (for KServe InferenceService), breaking NIMPipeline deployments (port 8000)
Solution: Changed default back to 8000 in deploy/nemo-instances/values.yaml:239
Problem: Embedding and retriever models are deployed by default, consuming 2 unnecessary GPUs
Solution: Added deployment control flags (deployEmbeddingModel, deployRetrieverModel) - disabled by default
Problem: Installation required running bash functions manually for CRD adoption, RBAC patching, and SCC binding
Solution: Converted bash functions to Helm hooks with proper execution ordering
Changes Made
Files Modified
Line 239: Changed evaluator NIM proxy port default from "80" to "8000"
Added lines 281-284: New deployment control flags
deployEmbeddingModel: false # Controls nimCacheEmbedding + nimPipelineEmbedding (1 GPU)
deployRetrieverModel: false # Controls nimCacheRetriever + nimPipelineRetriever (1 GPU)
2. deploy/nemo-infra/values.yaml (renamed from values.yaml.sample)
Renamed from .sample to standard Helm pattern
3. deploy/nemo-instances/templates/ - New Helm Hook Files
Evaluator Init Container Patch:
evaluator-init-patch-job.yaml - Post-install hook (weight 5) that adds EVALUATOR_IMAGE env var to evaluator deployment
evaluator-patch-rbac.yaml - RBAC resources (weight 0) for patch job
SCC Binding:
post-install-bind-scc-job.yaml - Post-install hook (weight 10) that binds nemocustomizer-sample SA to nemo-customizer-scc
post-install-bind-scc-rbac.yaml - RBAC resources (weight 5)
Resource Adoption:
pre-install-adopt-resources-job.yaml - Pre-install hook (weight -15) that adopts existing NeMo CRDs and cluster resources
pre-install-adopt-resources-rbac.yaml - RBAC resources (weight -20)
4. deploy/nemo-infra/templates/ - New Helm Hook Files
CRD Adoption:
pre-install-adopt-crds-job.yaml - Pre-install hook (weight -15) that adopts Argo Workflows and Volcano CRDs
pre-install-adopt-crds-rbac.yaml - RBAC resources (weight -20)
SCC Binding:
post-install-bind-scc-job.yaml - Post-install hook (weight 5) for SCC binding
post-install-bind-scc-rbac.yaml - RBAC resources (weight 0)
5. Conditional Wrapping - Model Templates
Wrapped with deployment control flags:
nimcache-embedding.yaml - {{- if .Values.deployEmbeddingModel }}
nimpipeline-embedding.yaml - {{- if .Values.deployEmbeddingModel }}
nimcache-retriever.yaml - {{- if .Values.deployRetrieverModel }}
nimpipeline-retriever.yaml - {{- if .Values.deployRetrieverModel }}
Helm Hook Execution Order
nemo-infra
nemo-instances