diff --git a/pkg/reconciler/integrationsource/resources/containersource.go b/pkg/reconciler/integrationsource/resources/containersource.go index d4e6e7e0a3b..95fb2a32aa1 100644 --- a/pkg/reconciler/integrationsource/resources/containersource.go +++ b/pkg/reconciler/integrationsource/resources/containersource.go @@ -63,7 +63,7 @@ func NewContainerSource(source *v1alpha1.IntegrationSource) *sourcesv1.Container } func generateEnvVarsFromStruct(prefix string, s interface{}) []corev1.EnvVar { - var envVars = makeSSLEnvVar() + var envVars []corev1.EnvVar // Use reflection to inspect the struct fields v := reflect.ValueOf(s) @@ -136,7 +136,7 @@ func generateEnvVarsFromStruct(prefix string, s interface{}) []corev1.EnvVar { // Function to create environment variables for Timer or AWS configurations dynamically func makeEnv(source *v1alpha1.IntegrationSource) []corev1.EnvVar { - var envVars []corev1.EnvVar + var envVars = makeSSLEnvVar() // Timer environment variables if source.Spec.Timer != nil { diff --git a/pkg/reconciler/integrationsource/resources/containersource_test.go b/pkg/reconciler/integrationsource/resources/containersource_test.go index 5bac6445343..669b4eeaabc 100644 --- a/pkg/reconciler/integrationsource/resources/containersource_test.go +++ b/pkg/reconciler/integrationsource/resources/containersource_test.go @@ -118,8 +118,6 @@ func TestGenerateEnvVarsFromStruct(t *testing.T) { // Expected environment variables including SSL settings want := []corev1.EnvVar{ - {Name: "CAMEL_KNATIVE_CLIENT_SSL_ENABLED", Value: "true"}, - {Name: "CAMEL_KNATIVE_CLIENT_SSL_CERT_PATH", Value: "/knative-custom-certs/knative-eventing-bundle.pem"}, {Name: "TEST_PREFIX_FIELD1", Value: "123"}, {Name: "TEST_PREFIX_FIELD2", Value: "true"}, {Name: "TEST_PREFIX_FIELD3", Value: "hello"},