Description
Problem
Helm template rendering fails with nil pointer evaluation errors when using override values files that contain partial ALB configurations. The specific error occurs in ingress-dotcms-cluster.yaml when accessing nested healthcheck and targetGroup values that don't exist in merged configurations.
Error: template: dotcms/templates/ingress-dotcms-cluster.yaml:16:58: executing dotcms/templates/ingress-dotcms-cluster.yaml at <.Values.ingress.alb.healthcheck.backendProtocol>: nil pointer evaluating interface {}.backendProtocol
Root Cause
Override files contain partial ALB configurations (e.g., alb: {} or alb.hosts only) that replace the complete nested healthcheck/targetGroup structure from base values.yaml during Helm's values merging process.
Solution Implemented
Updated templates to use dig function for safe nested value access with proper defaults:
- dig ingress alb healthcheck backendProtocol HTTP .Values
- dig ingress alb targetGroup stickiness enabled true .Values
Benefits
✅ Backwards compatible with existing override files
✅ Graceful fallback to sensible defaults
✅ No template rendering errors
✅ Enhanced ALB health check configurations when available
Acceptance Criteria
Additional Notes
[Any additional context or notes]
Description
Problem
Helm template rendering fails with nil pointer evaluation errors when using override values files that contain partial ALB configurations. The specific error occurs in ingress-dotcms-cluster.yaml when accessing nested healthcheck and targetGroup values that don't exist in merged configurations.
Error: template: dotcms/templates/ingress-dotcms-cluster.yaml:16:58: executing dotcms/templates/ingress-dotcms-cluster.yaml at <.Values.ingress.alb.healthcheck.backendProtocol>: nil pointer evaluating interface {}.backendProtocol
Root Cause
Override files contain partial ALB configurations (e.g., alb: {} or alb.hosts only) that replace the complete nested healthcheck/targetGroup structure from base values.yaml during Helm's values merging process.
Solution Implemented
Updated templates to use dig function for safe nested value access with proper defaults:
Benefits
✅ Backwards compatible with existing override files
✅ Graceful fallback to sensible defaults
✅ No template rendering errors
✅ Enhanced ALB health check configurations when available
Acceptance Criteria
Additional Notes
[Any additional context or notes]