Skip to content
This repository has been archived by the owner on Nov 9, 2022. It is now read-only.

Commit

Permalink
Fix merge for new objects
Browse files Browse the repository at this point in the history
```improvement operator
A bug has been fixed, that caused new Services to get assigned a different ClusterIP than specified.
```
  • Loading branch information
timebertt committed Jun 25, 2020
1 parent 8b4e881 commit 276bf6d
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions pkg/controller/managedresources/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -393,17 +393,12 @@ func (r *Reconciler) applyNewResources(newResourcesObjects []object, labelsToInj
defer wg.Done()

var (
current = obj.obj.DeepCopy()
resource = unstructuredToString(obj.obj)
scaledHorizontally = isScaled(obj.obj, horizontallyScaledObjects, equivalences)
scaledVertically = isScaled(obj.obj, verticallyScaledObjects, equivalences)
)

current := &unstructured.Unstructured{}
current.SetAPIVersion(obj.obj.GetAPIVersion())
current.SetKind(obj.obj.GetKind())
current.SetNamespace(obj.obj.GetNamespace())
current.SetName(obj.obj.GetName())

r.log.Info("Applying", "resource", resource)

results <- retry.RetryOnConflict(retry.DefaultBackoff, func() error {
Expand Down

0 comments on commit 276bf6d

Please sign in to comment.