Skip to content

Commit

Permalink
Remove proxy settings from fleetshard-sync
Browse files Browse the repository at this point in the history
  • Loading branch information
kylape committed Apr 18, 2024
1 parent 446da01 commit faefc90
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 188 deletions.
55 changes: 0 additions & 55 deletions fleetshard/pkg/central/reconciler/proxy.go

This file was deleted.

119 changes: 0 additions & 119 deletions fleetshard/pkg/central/reconciler/proxy_test.go

This file was deleted.

14 changes: 0 additions & 14 deletions fleetshard/pkg/central/reconciler/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"encoding/base64"
"encoding/json"
"fmt"
"net/url"
"reflect"
"sort"
"sync/atomic"
Expand Down Expand Up @@ -310,7 +309,6 @@ func (r *CentralReconciler) getInstanceConfig(remoteCentral *private.ManagedCent
func (r *CentralReconciler) applyCentralConfig(remoteCentral *private.ManagedCentral, central *v1alpha1.Central) error {
r.applyTelemetry(remoteCentral, central)
r.applyRoutes(central)
r.applyProxyConfig(central)
r.applyDeclarativeConfig(central)
r.applyAnnotations(remoteCentral, central)
return nil
Expand Down Expand Up @@ -348,18 +346,6 @@ func (r *CentralReconciler) applyDeclarativeConfig(central *v1alpha1.Central) {
central.Spec.Central.DeclarativeConfiguration = declarativeConfig
}

func (r *CentralReconciler) applyProxyConfig(central *v1alpha1.Central) {
if central.Spec.Customize == nil {
central.Spec.Customize = &v1alpha1.CustomizeSpec{}
}
auditLoggingURL := url.URL{Host: r.auditLogging.Endpoint(false)}
kubernetesURL := url.URL{
Host: "kubernetes.default.svc.cluster.local.:443",
}
envVars := getProxyEnvVars(central.Namespace, auditLoggingURL, kubernetesURL)
central.Spec.Customize.EnvVars = append(central.Spec.Customize.EnvVars, envVars...)
}

func (r *CentralReconciler) applyRoutes(central *v1alpha1.Central) {
if central.Spec.Central == nil {
central.Spec.Central = &v1alpha1.CentralComponentSpec{}
Expand Down

0 comments on commit faefc90

Please sign in to comment.