Skip to content

Commit

Permalink
Support manila setting route annotations
Browse files Browse the repository at this point in the history
This patch allows Manila to set its route annotations.

Depends-On: openstack-k8s-operators/manila-operator#282
  • Loading branch information
Akrog committed Jun 7, 2024
1 parent 670126e commit 121136e
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 6 deletions.
4 changes: 4 additions & 0 deletions apis/bases/core.openstack.org_openstackcontrolplanes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7171,6 +7171,10 @@ spec:
type: boolean
template:
properties:
apiTimeout:
default: 60
minimum: 10
type: integer
customServiceConfig:
default: '# add your customization here'
type: string
Expand Down
2 changes: 2 additions & 0 deletions apis/core/v1beta1/openstackcontrolplane_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,8 @@ func (r *OpenStackControlPlane) DefaultServices() {

// Manila
r.Spec.Manila.Template.Default()
initializeOverrideSpec(&r.Spec.Manila.APIOverride.Route, true)
r.Spec.Manila.Template.SetDefaultRouteAnnotations(r.Spec.Manila.APIOverride.Route.Annotations)

// Memcached
for key, template := range r.Spec.Memcached.Templates {
Expand Down
2 changes: 1 addition & 1 deletion apis/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ require (
github.com/openstack-k8s-operators/keystone-operator/api v0.3.1-0.20240525111221-1e3ee314289c
github.com/openstack-k8s-operators/lib-common/modules/common v0.3.1-0.20240606071226-62abb00585ce
github.com/openstack-k8s-operators/lib-common/modules/storage v0.3.1-0.20240531085522-94fdcd5ff4fd
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db
github.com/openstack-k8s-operators/neutron-operator/api v0.3.1-0.20240530061247-1aeb6862e523
github.com/openstack-k8s-operators/nova-operator/api v0.3.1-0.20240530073125-ab95f150cbec
Expand Down
4 changes: 2 additions & 2 deletions apis/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ github.com/openstack-k8s-operators/lib-common/modules/openstack v0.3.1-0.2024052
github.com/openstack-k8s-operators/lib-common/modules/openstack v0.3.1-0.20240529115306-9068d1417ae9/go.mod h1:OC9eAX0l35U8DD+ANolrVExTxeZbxKbrMVyiA3Dywow=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.3.1-0.20240531085522-94fdcd5ff4fd h1:tR0cs3CB7FtlwiAk/bMRl5sEXFs4ut5WNW7utBO5QAQ=
github.com/openstack-k8s-operators/lib-common/modules/storage v0.3.1-0.20240531085522-94fdcd5ff4fd/go.mod h1:HnATO+h6spGXATZ8fdOc+CJ47BiTV3ML1ZtGZa6yj3I=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97 h1:GyN2O0O2dECn9CL4dkvdTEVBQG+HjD+GLwHJM6a2nE8=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97/go.mod h1:DMSHD2lrHm2PK/+B+fCq3XXJvPJ8zLXu0Cb8OWdcgec=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5 h1:ai9dfLRdVAQygCrPBNvRnjiQN+DLfg+IsO+gC5Pt6pk=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5/go.mod h1:47/hHuGGXHZx7eWJpsPzwW9tem0Ghod85PSnlBasT0Y=
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db h1:9Egd/Hs/ZKyWl4vXkbivu/MG52Ww/kDrzE9KNYKuj7M=
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db/go.mod h1:tJbu9FBKNOpgN7T8SHhFGFnmKOg2EQsBWRKqE8+CPPA=
github.com/openstack-k8s-operators/neutron-operator/api v0.3.1-0.20240530061247-1aeb6862e523 h1:cM1r0ZsGOa7BBSPwi45AP4RQyYtB8EhMQpZ95zGEdqo=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7171,6 +7171,10 @@ spec:
type: boolean
template:
properties:
apiTimeout:
default: 60
minimum: 10
type: integer
customServiceConfig:
default: '# add your customization here'
type: string
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ require (
github.com/openstack-k8s-operators/lib-common/modules/certmanager v0.0.0-20240529115306-9068d1417ae9
github.com/openstack-k8s-operators/lib-common/modules/common v0.3.1-0.20240606071226-62abb00585ce
github.com/openstack-k8s-operators/lib-common/modules/test v0.3.1-0.20240529115306-9068d1417ae9
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db
github.com/openstack-k8s-operators/neutron-operator/api v0.3.1-0.20240530061247-1aeb6862e523
github.com/openstack-k8s-operators/nova-operator/api v0.3.1-0.20240530073125-ab95f150cbec
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ github.com/openstack-k8s-operators/lib-common/modules/storage v0.3.1-0.202405310
github.com/openstack-k8s-operators/lib-common/modules/storage v0.3.1-0.20240531085522-94fdcd5ff4fd/go.mod h1:HnATO+h6spGXATZ8fdOc+CJ47BiTV3ML1ZtGZa6yj3I=
github.com/openstack-k8s-operators/lib-common/modules/test v0.3.1-0.20240529115306-9068d1417ae9 h1:mqpVm5ugrQ13sqVVSDuVmPNDb0GS5rLBA+XkF0gU4n0=
github.com/openstack-k8s-operators/lib-common/modules/test v0.3.1-0.20240529115306-9068d1417ae9/go.mod h1:0h76CxD9g0z2Hk7fGFOZcjnzT1tQQ/yRNv3OXng+S/A=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97 h1:GyN2O0O2dECn9CL4dkvdTEVBQG+HjD+GLwHJM6a2nE8=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240528082305-04b02cfe0c97/go.mod h1:DMSHD2lrHm2PK/+B+fCq3XXJvPJ8zLXu0Cb8OWdcgec=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5 h1:ai9dfLRdVAQygCrPBNvRnjiQN+DLfg+IsO+gC5Pt6pk=
github.com/openstack-k8s-operators/manila-operator/api v0.3.1-0.20240607065123-84eee5519cb5/go.mod h1:47/hHuGGXHZx7eWJpsPzwW9tem0Ghod85PSnlBasT0Y=
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db h1:9Egd/Hs/ZKyWl4vXkbivu/MG52Ww/kDrzE9KNYKuj7M=
github.com/openstack-k8s-operators/mariadb-operator/api v0.3.1-0.20240514152407-b2bea62f05db/go.mod h1:tJbu9FBKNOpgN7T8SHhFGFnmKOg2EQsBWRKqE8+CPPA=
github.com/openstack-k8s-operators/neutron-operator/api v0.3.1-0.20240530061247-1aeb6862e523 h1:cM1r0ZsGOa7BBSPwi45AP4RQyYtB8EhMQpZ95zGEdqo=
Expand Down
2 changes: 2 additions & 0 deletions tests/functional/openstackoperator_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,8 @@ var _ = Describe("OpenStackOperator controller", func() {
Expect(OSCtlplane.Spec.Glance.APIOverride[name].Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Glance.APIOverride[name].Route.Annotations).Should(HaveKeyWithValue("api.glance.openstack.org/timeout", "60s"))
}
Expect(OSCtlplane.Spec.Manila.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Manila.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.manila.openstack.org/timeout", "60s"))
})

It("should create selfsigned issuer and public+internal CA and issuer", func() {
Expand Down

0 comments on commit 121136e

Please sign in to comment.