From f75d33b2c1b3623dd8290255b2a2ae2b2795496f Mon Sep 17 00:00:00 2001 From: Walter Medvedeo Date: Mon, 23 Sep 2024 14:37:02 +0200 Subject: [PATCH] SRVLOGIC-390: Adjust cors configuration for the dev profile deployments, and JS and DI deployments - property in the application-dev.properties can't start with %dev --- controllers/profiles/common/properties/managed.go | 2 +- controllers/profiles/common/properties/managed_test.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/controllers/profiles/common/properties/managed.go b/controllers/profiles/common/properties/managed.go index f0269e63c..af4d51f50 100644 --- a/controllers/profiles/common/properties/managed.go +++ b/controllers/profiles/common/properties/managed.go @@ -188,7 +188,7 @@ func NewManagedPropertyHandler(workflow *operatorapi.SonataFlow, platform *opera } func setDevProfileProperties(props *properties.Properties) { - props.Set(fmt.Sprintf("%%dev.%s", constants.QuarkusDevUICorsEnabled), "false") + props.Set(constants.QuarkusDevUICorsEnabled, "false") } // ApplicationManagedProperties immutable default application properties that can be used with any workflow based on Quarkus. diff --git a/controllers/profiles/common/properties/managed_test.go b/controllers/profiles/common/properties/managed_test.go index 3b8562aff..b713b70b6 100644 --- a/controllers/profiles/common/properties/managed_test.go +++ b/controllers/profiles/common/properties/managed_test.go @@ -470,7 +470,7 @@ func generateJobServiceWorkflowDevProperties() *properties.Properties { props.Set("kogito.events.processdefinitions.enabled", "false") props.Set("kogito.events.processinstances.enabled", "false") props.Set("kogito.events.usertasks.enabled", "false") - props.Set("%dev.quarkus.dev-ui.cors.enabled", "false") + props.Set("quarkus.dev-ui.cors.enabled", "false") props.Sort() return props } @@ -523,7 +523,7 @@ func generateDataIndexWorkflowDevProperties() *properties.Properties { props.Set("kogito.events.processdefinitions.enabled", "false") props.Set("kogito.events.processinstances.enabled", "false") props.Set("kogito.events.usertasks.enabled", "false") - props.Set("%dev.quarkus.dev-ui.cors.enabled", "false") + props.Set("quarkus.dev-ui.cors.enabled", "false") props.Sort() return props } @@ -581,7 +581,7 @@ func generateDataIndexAndJobServiceWorkflowDevProperties() *properties.Propertie props.Set("kogito.events.processdefinitions.enabled", "false") props.Set("kogito.events.processinstances.enabled", "false") props.Set("kogito.events.usertasks.enabled", "false") - props.Set("%dev.quarkus.dev-ui.cors.enabled", "false") + props.Set("quarkus.dev-ui.cors.enabled", "false") props.Sort() return props }