Skip to content

Commit

Permalink
changed app mob cert manager yaml reference
Browse files Browse the repository at this point in the history
  • Loading branch information
mbasha-dell committed Aug 14, 2023
1 parent bf2aa95 commit 42029bb
Showing 1 changed file with 1 addition and 18 deletions.
19 changes: 1 addition & 18 deletions pkg/modules/application_mobility.go
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ func ApplicationMobilityPrecheck(ctx context.Context, op utils.OperatorConfig, a
// AppMobilityCertManager - Install/Delete cert-manager
func AppMobilityCertManager(ctx context.Context, isDeleting bool, op utils.OperatorConfig, cr csmv1.ContainerStorageModule, ctrlClient crclient.Client) error {

yamlString, err := getAppMobCertManager(op, cr)
yamlString, err := getCertManager(op, cr)
if err != nil {
return err
}
Expand All @@ -327,23 +327,6 @@ func AppMobilityCertManager(ctx context.Context, isDeleting bool, op utils.Opera
return nil
}

// getAppMobilityCertManager - gets the cert-manager manifest from common
func getAppMobCertManager(op utils.OperatorConfig, cr csmv1.ContainerStorageModule) (string, error) {
yamlString := ""

certManagerPath := fmt.Sprintf("%s/moduleconfig/common/%s", op.ConfigDirectory, AppMobCertManagerManifest)
buf, err := os.ReadFile(filepath.Clean(certManagerPath))
if err != nil {
return yamlString, err
}

yamlString = string(buf)
appMobNamespace := cr.Namespace
yamlString = strings.ReplaceAll(yamlString, AppMobNamespace, appMobNamespace)

return yamlString, nil
}

// CreateVeleroAccess - Install/Delete velero-secret yaml from operator config
func CreateVeleroAccess(ctx context.Context, isDeleting bool, op utils.OperatorConfig, cr csmv1.ContainerStorageModule, ctrlClient crclient.Client) error {

Expand Down

0 comments on commit 42029bb

Please sign in to comment.