Check if helmRelease.Spec.Install is nil
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
This commit is contained in:
@@ -197,6 +197,10 @@ func createHelmReleaseCmdRun(cmd *cobra.Command, args []string) error {
|
||||
}
|
||||
|
||||
if helmReleaseArgs.crds != "" {
|
||||
if helmRelease.Spec.Install == nil {
|
||||
helmRelease.Spec.Install = &helmv2.Install{}
|
||||
}
|
||||
|
||||
helmRelease.Spec.Install.CRDs = helmv2.Create
|
||||
helmRelease.Spec.Upgrade = &helmv2.Upgrade{CRDs: helmv2.CRDsPolicy(helmReleaseArgs.crds.String())}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user