Skip to content

Commit 83005bc

Browse files
committed
[tlse] internal TLS support for telemetry aodh service
Creates certs for k8s service of the service operator when spec.tls.endpoint.internal.enabled: true For a service like nova which talks to multiple service internal endpoints, this has to be set for each of them for, like: ~~~ customServiceConfig: | [keystone_authtoken] insecure = true [placement] insecure = true [neutron] insecure = true [glance] insecure = true [cinder] insecure = true ~~~ Depends-On: openstack-k8s-operators/lib-common#428 Depends-On: openstack-k8s-operators#620 Depends-On: openstack-k8s-operators/telemetry-operator#310 Depends-On: openstack-k8s-operators/telemetry-operator#327 Depends-On: openstack-k8s-operators/telemetry-operator#330 Signed-off-by: Veronika Fisarova <[email protected]>
1 parent 55053b4 commit 83005bc

File tree

10 files changed

+316
-7
lines changed

10 files changed

+316
-7
lines changed

apis/bases/core.openstack.org_openstackcontrolplanes.yaml

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15384,6 +15384,112 @@ spec:
1538415384
type: object
1538515385
telemetry:
1538615386
properties:
15387+
apiOverride:
15388+
properties:
15389+
route:
15390+
properties:
15391+
metadata:
15392+
properties:
15393+
annotations:
15394+
additionalProperties:
15395+
type: string
15396+
type: object
15397+
labels:
15398+
additionalProperties:
15399+
type: string
15400+
type: object
15401+
type: object
15402+
spec:
15403+
properties:
15404+
alternateBackends:
15405+
items:
15406+
properties:
15407+
kind:
15408+
enum:
15409+
- Service
15410+
- ""
15411+
type: string
15412+
name:
15413+
type: string
15414+
weight:
15415+
format: int32
15416+
maximum: 256
15417+
minimum: 0
15418+
type: integer
15419+
type: object
15420+
maxItems: 3
15421+
type: array
15422+
host:
15423+
maxLength: 253
15424+
pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$
15425+
type: string
15426+
path:
15427+
pattern: ^/
15428+
type: string
15429+
port:
15430+
properties:
15431+
targetPort:
15432+
anyOf:
15433+
- type: integer
15434+
- type: string
15435+
x-kubernetes-int-or-string: true
15436+
required:
15437+
- targetPort
15438+
type: object
15439+
subdomain:
15440+
maxLength: 253
15441+
pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$
15442+
type: string
15443+
tls:
15444+
properties:
15445+
caCertificate:
15446+
type: string
15447+
certificate:
15448+
type: string
15449+
destinationCACertificate:
15450+
type: string
15451+
insecureEdgeTerminationPolicy:
15452+
type: string
15453+
key:
15454+
type: string
15455+
termination:
15456+
enum:
15457+
- edge
15458+
- reencrypt
15459+
- passthrough
15460+
type: string
15461+
required:
15462+
- termination
15463+
type: object
15464+
to:
15465+
properties:
15466+
kind:
15467+
enum:
15468+
- Service
15469+
- ""
15470+
type: string
15471+
name:
15472+
type: string
15473+
weight:
15474+
format: int32
15475+
maximum: 256
15476+
minimum: 0
15477+
type: integer
15478+
type: object
15479+
wildcardPolicy:
15480+
enum:
15481+
- None
15482+
- Subdomain
15483+
- ""
15484+
type: string
15485+
type: object
15486+
type: object
15487+
tls:
15488+
properties:
15489+
secretName:
15490+
type: string
15491+
type: object
15492+
type: object
1538715493
enabled:
1538815494
default: true
1538915495
type: boolean
@@ -15495,6 +15601,24 @@ spec:
1549515601
serviceUser:
1549615602
default: aodh
1549715603
type: string
15604+
tls:
15605+
properties:
15606+
api:
15607+
properties:
15608+
internal:
15609+
properties:
15610+
secretName:
15611+
type: string
15612+
type: object
15613+
public:
15614+
properties:
15615+
secretName:
15616+
type: string
15617+
type: object
15618+
type: object
15619+
caBundleSecretName:
15620+
type: string
15621+
type: object
1549815622
required:
1549915623
- apiImage
1550015624
- databaseInstance

apis/core/v1beta1/conditions.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,9 @@ const (
108108
// OpenStackControlPlaneTelemetryReadyCondition Status=True condition which indicates if OpenStack Telemetry service is configured and operational
109109
OpenStackControlPlaneTelemetryReadyCondition condition.Type = "OpenStackControlPlaneTelemetryReady"
110110

111+
// OpenStackControlPlaneExposeTelemetryReadyCondition Status=True condition which indicates if Telemetry is exposed via a route
112+
OpenStackControlPlaneExposeTelemetryReadyCondition condition.Type = "OpenStackControlPlaneExposeTelemetryReady"
113+
111114
// OpenStackControlPlaneServiceOverrideReadyCondition Status=True condition which indicates if OpenStack service override has created ok
112115
OpenStackControlPlaneServiceOverrideReadyCondition condition.Type = "OpenStackControlPlaneServiceOverrideReady"
113116

apis/core/v1beta1/openstackcontrolplane_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -547,6 +547,11 @@ type TelemetrySection struct {
547547
//+operator-sdk:csv:customresourcedefinitions:type=spec
548548
// Template - Overrides to use when creating the OpenStack Telemetry services
549549
Template telemetryv1.TelemetrySpec `json:"template,omitempty"`
550+
551+
// +kubebuilder:validation:Optional
552+
// +operator-sdk:csv:customresourcedefinitions:type=spec
553+
// APIOverride, provides the ability to override the generated manifest of several child resources.
554+
APIOverride Override `json:"apiOverride,omitempty"`
550555
}
551556

552557
// SwiftSection defines the desired state of Swift service

apis/core/v1beta1/zz_generated.deepcopy.go

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apis/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ require (
2424
github.com/openstack-k8s-operators/ovn-operator/api v0.3.1-0.20240227150317-d42793e452c2
2525
github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.20240229134606-d2a5a5abde9d
2626
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79
27-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5
27+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31
2828
github.com/rabbitmq/cluster-operator/v2 v2.6.0
2929
k8s.io/api v0.28.7
3030
k8s.io/apimachinery v0.28.7

apis/go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.2024022913460
128128
github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.20240229134606-d2a5a5abde9d/go.mod h1:ePH8U08vCJQ4dwTuh/nLiidqlNOPx/EuRWjIbSEW1hY=
129129
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79 h1:OPqHOID5/2sr4hZtvWdm03xje1GeCf/u6FiRViZXFwU=
130130
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79/go.mod h1:NW/gfy7soUXzx7H/JsOcqQ7GhBJ2DvrjEy4ZKr5uR8s=
131-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5 h1:j8Kj8+xQC2FQRkdVUwOgFAZlhFtMV1YygVCypxLmllw=
132-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5/go.mod h1:Css7ZpU59JmTX/GegION98Y6XFKceBx/zxQQHptwd+8=
131+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31 h1:duKTmS6gFGCkVw151HxATWtsRMVCws1Tka1WcbpL3Mo=
132+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31/go.mod h1:Css7ZpU59JmTX/GegION98Y6XFKceBx/zxQQHptwd+8=
133133
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
134134
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
135135
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

config/crd/bases/core.openstack.org_openstackcontrolplanes.yaml

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15384,6 +15384,112 @@ spec:
1538415384
type: object
1538515385
telemetry:
1538615386
properties:
15387+
apiOverride:
15388+
properties:
15389+
route:
15390+
properties:
15391+
metadata:
15392+
properties:
15393+
annotations:
15394+
additionalProperties:
15395+
type: string
15396+
type: object
15397+
labels:
15398+
additionalProperties:
15399+
type: string
15400+
type: object
15401+
type: object
15402+
spec:
15403+
properties:
15404+
alternateBackends:
15405+
items:
15406+
properties:
15407+
kind:
15408+
enum:
15409+
- Service
15410+
- ""
15411+
type: string
15412+
name:
15413+
type: string
15414+
weight:
15415+
format: int32
15416+
maximum: 256
15417+
minimum: 0
15418+
type: integer
15419+
type: object
15420+
maxItems: 3
15421+
type: array
15422+
host:
15423+
maxLength: 253
15424+
pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$
15425+
type: string
15426+
path:
15427+
pattern: ^/
15428+
type: string
15429+
port:
15430+
properties:
15431+
targetPort:
15432+
anyOf:
15433+
- type: integer
15434+
- type: string
15435+
x-kubernetes-int-or-string: true
15436+
required:
15437+
- targetPort
15438+
type: object
15439+
subdomain:
15440+
maxLength: 253
15441+
pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$
15442+
type: string
15443+
tls:
15444+
properties:
15445+
caCertificate:
15446+
type: string
15447+
certificate:
15448+
type: string
15449+
destinationCACertificate:
15450+
type: string
15451+
insecureEdgeTerminationPolicy:
15452+
type: string
15453+
key:
15454+
type: string
15455+
termination:
15456+
enum:
15457+
- edge
15458+
- reencrypt
15459+
- passthrough
15460+
type: string
15461+
required:
15462+
- termination
15463+
type: object
15464+
to:
15465+
properties:
15466+
kind:
15467+
enum:
15468+
- Service
15469+
- ""
15470+
type: string
15471+
name:
15472+
type: string
15473+
weight:
15474+
format: int32
15475+
maximum: 256
15476+
minimum: 0
15477+
type: integer
15478+
type: object
15479+
wildcardPolicy:
15480+
enum:
15481+
- None
15482+
- Subdomain
15483+
- ""
15484+
type: string
15485+
type: object
15486+
type: object
15487+
tls:
15488+
properties:
15489+
secretName:
15490+
type: string
15491+
type: object
15492+
type: object
1538715493
enabled:
1538815494
default: true
1538915495
type: boolean
@@ -15495,6 +15601,24 @@ spec:
1549515601
serviceUser:
1549615602
default: aodh
1549715603
type: string
15604+
tls:
15605+
properties:
15606+
api:
15607+
properties:
15608+
internal:
15609+
properties:
15610+
secretName:
15611+
type: string
15612+
type: object
15613+
public:
15614+
properties:
15615+
secretName:
15616+
type: string
15617+
type: object
15618+
type: object
15619+
caBundleSecretName:
15620+
type: string
15621+
type: object
1549815622
required:
1549915623
- apiImage
1550015624
- databaseInstance

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ require (
3636
github.com/openstack-k8s-operators/ovn-operator/api v0.3.1-0.20240227150317-d42793e452c2
3737
github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.20240229134606-d2a5a5abde9d
3838
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79
39-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5
39+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31
4040
github.com/operator-framework/api v0.20.0
4141
github.com/rabbitmq/cluster-operator/v2 v2.6.0
4242
go.uber.org/zap v1.27.0

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,8 +150,8 @@ github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.2024022913460
150150
github.com/openstack-k8s-operators/placement-operator/api v0.3.1-0.20240229134606-d2a5a5abde9d/go.mod h1:ePH8U08vCJQ4dwTuh/nLiidqlNOPx/EuRWjIbSEW1hY=
151151
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79 h1:OPqHOID5/2sr4hZtvWdm03xje1GeCf/u6FiRViZXFwU=
152152
github.com/openstack-k8s-operators/swift-operator/api v0.3.1-0.20240301170116-13941759ec79/go.mod h1:NW/gfy7soUXzx7H/JsOcqQ7GhBJ2DvrjEy4ZKr5uR8s=
153-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5 h1:j8Kj8+xQC2FQRkdVUwOgFAZlhFtMV1YygVCypxLmllw=
154-
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240301135657-444ba309cbb5/go.mod h1:Css7ZpU59JmTX/GegION98Y6XFKceBx/zxQQHptwd+8=
153+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31 h1:duKTmS6gFGCkVw151HxATWtsRMVCws1Tka1WcbpL3Mo=
154+
github.com/openstack-k8s-operators/telemetry-operator/api v0.3.1-0.20240305220843-2385f2581b31/go.mod h1:Css7ZpU59JmTX/GegION98Y6XFKceBx/zxQQHptwd+8=
155155
github.com/operator-framework/api v0.20.0 h1:A2YCRhr+6s0k3pRJacnwjh1Ue8BqjIGuQ2jvPg9XCB4=
156156
github.com/operator-framework/api v0.20.0/go.mod h1:rXPOhrQ6mMeXqCmpDgt1ALoar9ZlHL+Iy5qut9R99a4=
157157
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

0 commit comments

Comments
 (0)