Skip to content

Commit

Permalink
Merge pull request #122 from 3scale-ops/fix/service-reconcile-loop
Browse files Browse the repository at this point in the history
fix/service-reconcile-loop
  • Loading branch information
3scale-robot authored Sep 20, 2021
2 parents 945f7d5 + 97625e6 commit 34af7d2
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 29 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
SHELL:=/bin/bash
# Current Operator version
VERSION ?= 0.10.6
VERSION ?= 0.10.7
# Default catalog image
CATALOG_IMG ?= quay.io/3scaleops/saas-operator-bundle:catalog
# Default bundle image tag
Expand Down Expand Up @@ -96,7 +96,7 @@ go-bindata:
# Download kind locally if necessary
KIND = $(shell pwd)/bin/kind
kind:
$(call go-get-tool,$(KIND),sigs.k8s.io/kind@v0.9.0)
$(call go-get-tool,$(KIND),sigs.k8s.io/kind@v0.11.1)

# Download crd-ref-docs locally if necessary
CRD_REFDOCS = $(shell pwd)/bin/crd-ref-docs
Expand Down Expand Up @@ -228,7 +228,7 @@ get-new-release:
kind-create: ## runs a k8s kind cluster for testing
kind-create: export KUBECONFIG = ${PWD}/kubeconfig
kind-create: tmp $(KIND)
$(KIND) create cluster --wait 5m
$(KIND) create cluster --wait 5m --image kindest/node:v1.20.0

kind-delete: ## deletes the kind cluster
kind-delete: $(KIND)
Expand Down
6 changes: 3 additions & 3 deletions bundle/manifests/saas-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ metadata:
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
repository: https://github.com/3scale/saas-operator
support: Red Hat
name: saas-operator.v0.10.6
name: saas-operator.v0.10.7
namespace: placeholder
spec:
apiservicedefinitions: {}
Expand Down Expand Up @@ -2993,7 +2993,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.annotations['olm.targetNamespaces']
image: quay.io/3scale/saas-operator:0.10.6
image: quay.io/3scale/saas-operator:0.10.7
livenessProbe:
httpGet:
path: /healthz
Expand Down Expand Up @@ -3380,4 +3380,4 @@ spec:
provider:
name: Red Hat
url: https://www.3scale.net/
version: 0.10.6
version: 0.10.7
2 changes: 1 addition & 1 deletion config/manager/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ kind: Kustomization
images:
- name: controller
newName: quay.io/3scale/saas-operator
newTag: 0.10.6
newTag: 0.10.7
16 changes: 8 additions & 8 deletions pkg/assets/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/basereconciler/reconcile_resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ func (r *Reconciler) ReconcileOwnedResources(ctx context.Context, owner client.O
func ServiceExcludes(fn GeneratorFunction) []string {
svc := fn().(*corev1.Service)
paths := []string{}
paths = append(paths, "/spec/clusterIP", "/spec/clusterIPs")
paths = append(paths, "/spec/clusterIP", "/spec/clusterIPs", "/spec/ipFamilies", "/spec/ipFamilyPolicy")
for idx := range svc.Spec.Ports {
paths = append(paths, fmt.Sprintf("/spec/ports/%d/nodePort", idx))
}
Expand Down
12 changes: 0 additions & 12 deletions pkg/generators/common_blocks/service/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"strings"

saasv1alpha1 "github.com/3scale/saas-operator/api/v1alpha1"
"github.com/3scale/saas-operator/pkg/basereconciler"
corev1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/util/intstr"
)
Expand Down Expand Up @@ -65,14 +64,3 @@ func Ports(ports ...corev1.ServicePort) []corev1.ServicePort {
list := []corev1.ServicePort{}
return append(list, ports...)
}

// Excludes generates the list of excluded paths for a Service resource
func Excludes(fn basereconciler.GeneratorFunction) []string {
svc := fn().(*corev1.Service)
paths := []string{}
paths = append(paths, "/spec/clusterIP")
for idx := range svc.Spec.Ports {
paths = append(paths, fmt.Sprintf("/spec/ports/%d/nodePort", idx))
}
return paths
}
2 changes: 1 addition & 1 deletion pkg/version/version.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package version

const (
version string = "v0.10.6"
version string = "v0.10.7"
)

// Current returns the current marin3r operator version
Expand Down

0 comments on commit 34af7d2

Please sign in to comment.