Skip to content

Commit

Permalink
apiTimout keystone and barbican testing
Browse files Browse the repository at this point in the history
Signed-off-by: Veronika Fisarova <[email protected]>
  • Loading branch information
Deydra71 committed Jan 15, 2025
1 parent 39c4136 commit 5dd2be2
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
4 changes: 4 additions & 0 deletions apis/core/v1beta1/openstackcontrolplane_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -771,6 +771,8 @@ func (r *OpenStackControlPlane) DefaultServices() {
r.Spec.Keystone.Template = &keystonev1.KeystoneAPISpecCore{}
}
r.Spec.Keystone.Template.Default()
initializeOverrideSpec(&r.Spec.Keystone.APIOverride.Route, true)
r.Spec.Keystone.Template.SetDefaultRouteAnnotations(r.Spec.Keystone.APIOverride.Route.Annotations)
}

// Manila
Expand Down Expand Up @@ -908,6 +910,8 @@ func (r *OpenStackControlPlane) DefaultServices() {
r.Spec.Barbican.Template = &barbicanv1.BarbicanSpecCore{}
}
r.Spec.Barbican.Template.Default()
initializeOverrideSpec(&r.Spec.Barbican.APIOverride.Route, true)
r.Spec.Barbican.Template.SetDefaultRouteAnnotations(r.Spec.Barbican.APIOverride.Route.Annotations)
}

// Designate
Expand Down
12 changes: 12 additions & 0 deletions tests/functional/ctlplane/openstackoperator_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -590,6 +590,12 @@ var _ = Describe("OpenStackOperator controller", func() {
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("api.aodh.openstack.org/timeout", "60s"))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.keystone.openstack.org/timeout", "60s"))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "90s"))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.barbican.openstack.org/timeout", "90s"))
})

It("should create selfsigned issuer and public+internal CA and issuer", func() {
Expand Down Expand Up @@ -867,6 +873,12 @@ var _ = Describe("OpenStackOperator controller", func() {
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("api.aodh.openstack.org/timeout", "60s"))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
Expect(OSCtlplane.Spec.Keystone.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.keystone.openstack.org/timeout", "60s"))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route).Should(Not(BeNil()))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "90s"))
Expect(OSCtlplane.Spec.Barbican.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.barbican.openstack.org/timeout", "90s"))
})

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

0 comments on commit 5dd2be2

Please sign in to comment.