Skip to content

Commit

Permalink
Update Samples and configure Swift backend for Glance
Browse files Browse the repository at this point in the history
The unsupported File backend is currently used in most of the samples.
They are not consistent even with the documentation, where we suggest to
add replicas: 0 to the glance service until a backend is chosen.
Considering we have Swift deployed by default, this patch fixes the
Glance samples and add Swift as a backend. This change will be
reflected in the openstack-operator guide as well.

Signed-off-by: Francesco Pantano <[email protected]>
  • Loading branch information
fmount committed Oct 14, 2024
1 parent b70fd8a commit b7e0084
Show file tree
Hide file tree
Showing 11 changed files with 159 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,24 @@ spec:
template:
secret: osp-secret
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
cinder:
template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,25 @@ spec:
template:
secret: osp-secret
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
keystoneEndpoint: default
glanceAPIs:
default:
replicas: 1
type: single
cinder:
template:
databaseInstance: openstack
Expand Down Expand Up @@ -149,3 +160,12 @@ spec:
ipaddr: 172.17.0.80
port: 10514
cloNamespace: openshift-logging
swift:
enabled: true
template:
swiftRing:
ringReplicas: 1
swiftStorage:
replicas: 1
swiftProxy:
replicas: 1
13 changes: 12 additions & 1 deletion config/samples/core_v1beta1_openstackcontrolplane_galera.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,24 @@ spec:
template:
secret: osp-secret
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
cinder:
template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,18 @@ spec:
secret: osp-secret
glance:
template:
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
databaseInstance: openstack
storage:
storageClass: ""
Expand All @@ -61,7 +73,6 @@ spec:
glanceAPIs:
default:
replicas: 1
type: single
cinder:
template:
databaseInstance: openstack
Expand Down Expand Up @@ -213,3 +224,11 @@ spec:
replicas: 0
networkAttachments:
- designate
swift:
template:
swiftRing:
ringReplicas: 1
swiftStorage:
replicas: 1
swiftProxy:
replicas: 1
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,18 @@ spec:
default:
route: {}
template:
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
databaseInstance: openstack
storage:
storageClass: ""
Expand All @@ -62,7 +74,6 @@ spec:
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
override:
service:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,25 @@ spec:
route: {}
template:
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
secret: osp-secret
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
override:
service:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,25 @@ spec:
route: {}
template:
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
secret: osp-secret
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
override:
service:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,25 @@ spec:
route: {}
template:
databaseInstance: openstack
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
storage:
storageClass: ""
storageRequest: 10G
secret: osp-secret
keystoneEndpoint: default
glanceAPIs:
default:
type: single
replicas: 1
override:
service:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,20 @@ spec:
storageRequest: 10G
secret: osp-secret
keystoneEndpoint: default
customServiceConfig: |
[DEFAULT]
enabled_backends = default_backend:swift
[glance_store]
default_backend = default_backend
[default_backend]
swift_store_create_container_on_put = True
swift_store_auth_version = 3
swift_store_auth_address = {{ .KeystoneInternalURL }}
swift_store_endpoint_type = internalURL
swift_store_user = service:glance
swift_store_key = {{ .ServicePassword }}
glanceAPIs:
default:
type: single
replicas: 1
override:
service:
Expand Down
17 changes: 17 additions & 0 deletions tests/kuttl/tests/ctlplane-collapsed/01-assert-collapsed-cell.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,15 @@ spec:
replicas: 1
barbicanKeystoneListener:
replicas: 1
swift:
enabled: true
template:
swiftRing:
ringReplicas: 1
swiftStorage:
replicas: 1
swiftProxy:
replicas: 1
tls:
ingress:
ca:
Expand Down Expand Up @@ -199,6 +208,10 @@ status:
reason: Ready
status: "True"
type: OpenStackControlPlaneExposePlacementAPIReady
- message: OpenStackControlPlane swift service exposed
reason: Ready
status: "True"
type: OpenStackControlPlaneExposeSwiftReady
- message: OpenStackControlPlane Glance completed
reason: Ready
status: "True"
Expand Down Expand Up @@ -239,6 +252,10 @@ status:
reason: Ready
status: "True"
type: OpenStackControlPlaneRabbitMQReady
- message: OpenStackControlPlane Swift completed
reason: Ready
status: "True"
type: OpenStackControlPlaneSwiftReady
- message: OpenStackControlPlane Telemetry completed
reason: Ready
status: "True"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,15 @@ spec:
duration: 87600h0m0s
cert:
duration: 43800h0m0s
swift:
enabled: true
template:
swiftRing:
ringReplicas: 1
swiftStorage:
replicas: 1
swiftProxy:
replicas: 1
status:
conditions:
- message: Setup complete
Expand Down Expand Up @@ -202,6 +211,10 @@ status:
reason: Ready
status: "True"
type: OpenStackControlPlaneExposePlacementAPIReady
- message: OpenStackControlPlane swift service exposed
reason: Ready
status: "True"
type: OpenStackControlPlaneExposeSwiftReady
- message: OpenStackControlPlane Glance completed
reason: Ready
status: "True"
Expand Down Expand Up @@ -242,6 +255,10 @@ status:
reason: Ready
status: "True"
type: OpenStackControlPlaneRabbitMQReady
- message: OpenStackControlPlane Swift completed
reason: Ready
status: "True"
type: OpenStackControlPlaneSwiftReady
- message: OpenStackControlPlane Telemetry completed
reason: Ready
status: "True"
Expand Down

0 comments on commit b7e0084

Please sign in to comment.