Skip to content

Commit

Permalink
remove dns healthcheck probes
Browse files Browse the repository at this point in the history
update manifests and bundle

upgrade controller-gen to 0.14.0 (Kuadrant#460)

dns: Bump DNS Operator version

propagate health check to DNS Records
  • Loading branch information
philbrookes committed Apr 16, 2024
1 parent 6ba870a commit e586a45
Show file tree
Hide file tree
Showing 30 changed files with 772 additions and 1,453 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ endif
LIMITADOR_OPERATOR_BUNDLE_IMG ?= quay.io/kuadrant/limitador-operator-bundle:$(LIMITADOR_OPERATOR_BUNDLE_IMG_TAG)

## dns
DNS_OPERATOR_VERSION ?= 0.1.0
DNS_OPERATOR_VERSION ?= latest

kuadrantdns_bundle_is_semantic := $(call is_semantic_version,$(DNS_OPERATOR_VERSION))
ifeq (latest,$(DNS_OPERATOR_VERSION))
Expand Down
22 changes: 10 additions & 12 deletions api/v1alpha1/dnspolicy_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ import (
gatewayapiv1 "sigs.k8s.io/gateway-api/apis/v1"
gatewayapiv1alpha2 "sigs.k8s.io/gateway-api/apis/v1alpha2"

kuadrantdnsv1alpha1 "github.com/kuadrant/dns-operator/api/v1alpha1"

"github.com/kuadrant/kuadrant-operator/pkg/library/kuadrant"
)

Expand Down Expand Up @@ -215,14 +213,14 @@ type DNSPolicyList struct {
// By default, this health check will be applied to each unique DNS A Record for
// the listeners assigned to the target gateway
type HealthCheckSpec struct {
Endpoint string `json:"endpoint,omitempty"`
Port *int `json:"port,omitempty"`
Protocol *kuadrantdnsv1alpha1.HealthProtocol `json:"protocol,omitempty"`
FailureThreshold *int `json:"failureThreshold,omitempty"`
AdditionalHeadersRef *kuadrantdnsv1alpha1.AdditionalHeadersRef `json:"additionalHeadersRef,omitempty"`
ExpectedResponses []int `json:"expectedResponses,omitempty"`
AllowInsecureCertificates bool `json:"allowInsecureCertificates,omitempty"`
Interval *metav1.Duration `json:"interval,omitempty"`
Endpoint string `json:"endpoint,omitempty"`
Port *int `json:"port,omitempty"`
Protocol *string `json:"protocol,omitempty"`
FailureThreshold *int `json:"failureThreshold,omitempty"`
AdditionalHeadersRef *string `json:"additionalHeadersRef,omitempty"`
ExpectedResponses []int `json:"expectedResponses,omitempty"`
AllowInsecureCertificates bool `json:"allowInsecureCertificates,omitempty"`
Interval *metav1.Duration `json:"interval,omitempty"`
}

func (s *HealthCheckSpec) Validate() error {
Expand All @@ -243,7 +241,7 @@ func (s *HealthCheckSpec) Default() {
}

if s.Protocol == nil {
protocol := kuadrantdnsv1alpha1.HttpsProtocol
protocol := "HTTPS"
s.Protocol = &protocol
}
}
Expand Down Expand Up @@ -311,7 +309,7 @@ func (p *DNSPolicy) WithTargetGateway(gwName string) *DNSPolicy {

//HealthCheck

func (p *DNSPolicy) WithHealthCheckFor(endpoint string, port *int, protocol kuadrantdnsv1alpha1.HealthProtocol, failureThreshold *int) *DNSPolicy {
func (p *DNSPolicy) WithHealthCheckFor(endpoint string, port *int, protocol string, failureThreshold *int) *DNSPolicy {
return p.WithHealthCheck(HealthCheckSpec{
Endpoint: endpoint,
Port: port,
Expand Down
5 changes: 2 additions & 3 deletions api/v1alpha1/zz_generated.deepcopy.go

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

28 changes: 9 additions & 19 deletions bundle/manifests/kuadrant-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ metadata:
capabilities: Basic Install
categories: Integration & Delivery
containerImage: quay.io/kuadrant/kuadrant-operator:latest
createdAt: "2024-03-25T09:38:12Z"
createdAt: "2024-04-11T14:20:56Z"
operators.operatorframework.io/builder: operator-sdk-v1.32.0
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
repository: https://github.com/Kuadrant/kuadrant-operator
Expand Down Expand Up @@ -262,6 +262,14 @@ spec:
- patch
- update
- watch
- apiGroups:
- ""
resources:
- namespaces
verbs:
- get
- list
- watch
- apiGroups:
- extensions.istio.io
resources:
Expand Down Expand Up @@ -347,24 +355,6 @@ spec:
- get
- patch
- update
- apiGroups:
- kuadrant.io
resources:
- dnshealthcheckprobes
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- kuadrant.io
resources:
- dnshealthcheckprobes/status
verbs:
- get
- apiGroups:
- kuadrant.io
resources:
Expand Down
9 changes: 1 addition & 8 deletions bundle/manifests/kuadrant.io_dnspolicies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,7 @@ spec:
the listeners assigned to the target gateway
properties:
additionalHeadersRef:
properties:
name:
type: string
required:
- name
type: object
type: string
allowInsecureCertificates:
type: boolean
endpoint:
Expand All @@ -89,8 +84,6 @@ spec:
port:
type: integer
protocol:
description: HealthProtocol represents the protocol to use when
making a health check request
type: string
type: object
loadBalancing:
Expand Down
2 changes: 1 addition & 1 deletion bundle/metadata/dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ dependencies:
- type: olm.package
value:
packageName: dns-operator
version: "0.1.0"
version: "0.0.0"
- type: olm.package
value:
packageName: cert-manager
Expand Down
9 changes: 1 addition & 8 deletions config/crd/bases/kuadrant.io_dnspolicies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,7 @@ spec:
the listeners assigned to the target gateway
properties:
additionalHeadersRef:
properties:
name:
type: string
required:
- name
type: object
type: string
allowInsecureCertificates:
type: boolean
endpoint:
Expand All @@ -88,8 +83,6 @@ spec:
port:
type: integer
protocol:
description: HealthProtocol represents the protocol to use when
making a health check request
type: string
type: object
loadBalancing:
Expand Down
2 changes: 1 addition & 1 deletion config/dependencies/dns/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
resources:
- github.com/kuadrant/dns-operator/config/default?ref=v0.1.0
- github.com/kuadrant/dns-operator/config/default?ref=main

patches:
- path: deployment_patch.yaml
Expand Down
26 changes: 8 additions & 18 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,14 @@ rules:
- patch
- update
- watch
- apiGroups:
- ""
resources:
- namespaces
verbs:
- get
- list
- watch
- apiGroups:
- extensions.istio.io
resources:
Expand Down Expand Up @@ -195,24 +203,6 @@ rules:
- get
- patch
- update
- apiGroups:
- kuadrant.io
resources:
- dnshealthcheckprobes
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- kuadrant.io
resources:
- dnshealthcheckprobes/status
verbs:
- get
- apiGroups:
- kuadrant.io
resources:
Expand Down
Loading

0 comments on commit e586a45

Please sign in to comment.