Merge "Remove deprecated glance config options"

This commit is contained in:
Zuul 2024-08-23 16:57:49 +00:00 committed by Gerrit Code Review
commit d6090047b8
9 changed files with 65 additions and 35 deletions

View File

@ -14,7 +14,7 @@ apiVersion: v1
appVersion: v1.0.0
description: OpenStack-Helm Glance
name: glance
version: 0.4.26
version: 0.5.0
home: https://docs.openstack.org/glance/latest/
icon: https://www.openstack.org/themes/openstack/images/project-mascots/Glance/OpenStack_Project_Glance_vertical.png
sources:

View File

@ -72,27 +72,25 @@ limitations under the License.
{{- $_ := tuple "image" "public" "api" . | include "helm-toolkit.endpoints.keystone_endpoint_uri_lookup" | set .Values.conf.glance.DEFAULT "public_endpoint" -}}
{{- end -}}
{{- if empty .Values.conf.glance.glance_store.stores -}}
{{- if empty .Values.conf.glance.DEFAULT.enabled_backends -}}
{{- if eq .Values.storage "rbd" }}
{{- $_ := "file, http, rbd" | set .Values.conf.glance.glance_store "stores" -}}
{{- end -}}
{{- if eq .Values.storage "pvc" }}
{{- $_ := "file, http" | set .Values.conf.glance.glance_store "stores" -}}
{{- end -}}
{{ if or (eq .Values.storage "radosgw") (eq .Values.storage "swift") }}
{{- $_ := "file, http, swift" | set .Values.conf.glance.glance_store "stores" -}}
{{- $_ := "file:file,http:http,rbd:rbd" | set .Values.conf.glance.DEFAULT "enabled_backends" -}}
{{- else if or (eq .Values.storage "radosgw") (eq .Values.storage "swift") }}
{{- $_ := "file:file,http:http,swift:swift" | set .Values.conf.glance.DEFAULT "enabled_backends" -}}
{{- else -}}
{{/* pvc, local (hostPath) or other/ephemeral (emptyDir) */}}
{{- $_ := "file:file,http:http" | set .Values.conf.glance.DEFAULT "enabled_backends" -}}
{{- end -}}
{{- end -}}
{{- if empty .Values.conf.glance.glance_store.default_store -}}
{{- if empty .Values.conf.glance.glance_store.default_backend -}}
{{- if eq .Values.storage "rbd" }}
{{- $_ := "rbd" | set .Values.conf.glance.glance_store "default_store" -}}
{{- end -}}
{{- if eq .Values.storage "pvc" }}
{{- $_ := "file" | set .Values.conf.glance.glance_store "default_store" -}}
{{- end -}}
{{ if or (eq .Values.storage "radosgw") (eq .Values.storage "swift") }}
{{- $_ := "swift" | set .Values.conf.glance.glance_store "default_store" -}}
{{- $_ := "rbd" | set .Values.conf.glance.glance_store "default_backend" -}}
{{- else if or (eq .Values.storage "radosgw") (eq .Values.storage "swift") }}
{{- $_ := "swift" | set .Values.conf.glance.glance_store "default_backend" -}}
{{- else -}}
{{/* pvc, local (hostPath) or other/ephemeral (emptyDir) */}}
{{- $_ := "file" | set .Values.conf.glance.glance_store "default_backend" -}}
{{- end -}}
{{- end -}}

View File

@ -103,19 +103,19 @@ spec:
- chown
- -R
- "glance:"
- {{ .Values.conf.glance.glance_store.filesystem_store_datadir }}
- {{ .Values.conf.glance.file.filesystem_store_datadir }}
volumeMounts:
- name: pod-tmp
mountPath: /tmp
- name: glance-images
mountPath: {{ .Values.conf.glance.glance_store.filesystem_store_datadir }}
mountPath: {{ .Values.conf.glance.file.filesystem_store_datadir }}
{{ if eq .Values.storage "rbd" }}
- name: ceph-keyring-placement
{{ tuple $envAll "glance_api" | include "helm-toolkit.snippets.image" | indent 10 }}
{{ dict "envAll" $envAll "application" "glance" "container" "ceph_keyring_placement" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }}
env:
- name: RBD_STORE_USER
value: {{ .Values.conf.glance.glance_store.rbd_store_user | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_user | quote }}
command:
- /tmp/ceph-keyring.sh
volumeMounts:
@ -258,11 +258,11 @@ spec:
{{- end }}
{{- end }}
- name: glance-etc
mountPath: {{ .Values.conf.glance.glance_store.swift_store_config_file }}
mountPath: {{ .Values.conf.glance.swift.swift_store_config_file }}
subPath: swift-store.conf
readOnly: true
- name: glance-images
mountPath: {{ .Values.conf.glance.glance_store.filesystem_store_datadir }}
mountPath: {{ .Values.conf.glance.file.filesystem_store_datadir }}
{{- if eq .Values.storage "cinder" }}
- name: host-rootfs
mountPath: /mnt/host-rootfs
@ -338,7 +338,12 @@ spec:
- name: glance-images
persistentVolumeClaim:
claimName: glance-images
{{ else }}
{{ else if eq .Values.storage "local" }}
- name: glance-images
hostPath:
path: {{ .Values.conf.glance.file.filesystem_store_datadir }}
type: DirectoryOrCreate
{{- else }}
- name: glance-images
emptyDir: {}
{{- end }}

View File

@ -112,17 +112,17 @@ spec:
value: {{ .Values.storage | quote }}
{{- if eq .Values.storage "rbd" }}
- name: RBD_POOL_NAME
value: {{ .Values.conf.glance.glance_store.rbd_store_pool | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_pool | quote }}
- name: RBD_POOL_APP_NAME
value: {{ .Values.conf.software.rbd.rbd_store_pool_app_name | quote }}
- name: RBD_POOL_USER
value: {{ .Values.conf.glance.glance_store.rbd_store_user | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_user | quote }}
- name: RBD_POOL_REPLICATION
value: {{ .Values.conf.glance.glance_store.rbd_store_replication | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_replication | quote }}
- name: RBD_POOL_CRUSH_RULE
value: {{ .Values.conf.glance.glance_store.rbd_store_crush_rule | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_crush_rule | quote }}
- name: RBD_POOL_CHUNK_SIZE
value: {{ .Values.conf.glance.glance_store.rbd_store_chunk_size | quote }}
value: {{ .Values.conf.glance.rbd.rbd_store_chunk_size | quote }}
- name: RBD_POOL_SECRET
value: {{ .Values.secrets.rbd | quote }}
{{ end }}

View File

@ -260,6 +260,10 @@ conf:
memcache_security_strategy: ENCRYPT
service_type: image
glance_store:
# Since 2024.1 this section must contain the only key 'default_backend'.
# Other keys should be defined in the corresponding per-backend sections.
# This is for backward compatibility.
filesystem_store_datadir: /var/lib/glance/images
cinder_catalog_info: volumev3::internalURL
rbd_store_chunk_size: 8
rbd_store_replication: 3
@ -267,7 +271,28 @@ conf:
rbd_store_pool: glance.images
rbd_store_user: glance
rbd_store_ceph_conf: /etc/ceph/ceph.conf
default_swift_reference: ref1
swift_store_container: glance
swift_store_create_container_on_put: true
swift_store_config_file: /etc/glance/swift-store.conf
swift_store_endpoint_type: internalURL
file:
filesystem_store_datadir: /var/lib/glance/images
# These two sections os_glance_tasks_store and os_glance_staging_store
# are mandatory. Glance will be unable to delete images from if these
# two are not properly configured.
os_glance_tasks_store:
filesystem_store_datadir: /var/lib/glance/tmp/os_glance_tasks_store
os_glance_staging_store:
filesystem_store_datadir: /var/lib/glance/tmp/os_glance_staging_store
rbd:
rbd_store_chunk_size: 8
rbd_store_replication: 3
rbd_store_crush_rule: replicated_rule
rbd_store_pool: glance.images
rbd_store_user: glance
rbd_store_ceph_conf: /etc/ceph/ceph.conf
swift:
default_swift_reference: ref1
swift_store_container: glance
swift_store_create_container_on_put: true

View File

@ -7,6 +7,7 @@ conf:
keystone_authtoken:
cafile: /etc/glance/certs/ca.crt
glance_store:
# This option has been removed in 2024.1
https_ca_certificates_file: /etc/glance/certs/ca.crt
swift_store_cacert: /etc/glance/certs/ca.crt
oslo_messaging_rabbit:

View File

@ -60,4 +60,5 @@ glance:
- 0.4.24 Do not attach backend pvc to storage init pod
- 0.4.25 Allow customisation of pvc storage accessMode so we can run multiple api pods
- 0.4.26 Use quay.io/airshipit/kubernetes-entrypoint:latest-ubuntu_focal by default
- 0.5.0 Remove deprecated config options `stores` and `default_store`
...

View File

@ -84,7 +84,7 @@
- ./tools/deployment/component/common/memcached.sh
- ./tools/deployment/component/keystone/keystone.sh
- ./tools/deployment/component/heat/heat.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/glance/glance.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
- ./tools/deployment/component/compute-kit/openvswitch.sh
- ./tools/deployment/component/compute-kit/libvirt.sh
- ./tools/deployment/component/compute-kit/compute-kit.sh
@ -138,7 +138,7 @@
- ./tools/deployment/component/common/memcached.sh
- ./tools/deployment/component/keystone/keystone.sh
- - ./tools/deployment/component/heat/heat.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/glance/glance.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
- ./tools/deployment/component/compute-kit/openvswitch.sh
- ./tools/deployment/component/compute-kit/libvirt.sh
- ./tools/deployment/component/compute-kit/compute-kit.sh
@ -168,7 +168,7 @@
- ./tools/deployment/component/common/memcached.sh
- ./tools/deployment/component/keystone/keystone.sh
- - ./tools/deployment/component/heat/heat.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/glance/glance.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
- ./tools/deployment/component/compute-kit/openvswitch.sh
- ./tools/deployment/component/compute-kit/libvirt.sh
- ./tools/deployment/component/compute-kit/compute-kit.sh
@ -194,7 +194,7 @@
- ./tools/deployment/component/common/memcached.sh
- ./tools/deployment/component/keystone/keystone.sh
- - ./tools/deployment/component/heat/heat.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/glance/glance.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
- ./tools/deployment/component/compute-kit/openvswitch.sh
- ./tools/deployment/component/compute-kit/libvirt.sh
- ./tools/deployment/component/ovn/ovn.sh
@ -299,7 +299,7 @@
- ./tools/deployment/common/prepare-charts.sh
- ./tools/deployment/common/setup-client.sh
- ./tools/deployment/common/ingress.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/common/openstack.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/common/openstack.sh
- export HELM_TESTS_TRIES=3; export OSH_TEST_TIMEOUT=1200; ./tools/deployment/common/run-helm-tests.sh openstack
- ./tools/deployment/common/use-it.sh
- ./tools/deployment/common/force-cronjob-run.sh
@ -373,7 +373,7 @@
- ./tools/deployment/component/common/memcached.sh
- ./tools/deployment/component/keystone/keystone.sh
- - ./tools/deployment/component/heat/heat.sh
- export GLANCE_BACKEND=memory; ./tools/deployment/component/glance/glance.sh
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
- ./tools/deployment/component/compute-kit/openvswitch.sh
- ./tools/deployment/component/compute-kit/libvirt.sh
- ./tools/deployment/component/compute-kit/compute-kit.sh

View File

@ -34,7 +34,7 @@
- openstack-helm-compute-kit-2023-2-ubuntu_jammy # 3 nodes
- openstack-helm-compute-kit-ovn-2023-2-ubuntu_jammy # 3 nodes
# 2024.1
- openstack-helm-umbrella-2024-1-ubuntu_jammy # 3 nodes
- openstack-helm-umbrella-2024-1-ubuntu_jammy # 3 nodes rook
- openstack-helm-tls-2024-1-ubuntu_jammy # 3 nodes rook
- openstack-helm-cinder-2024-1-ubuntu_jammy # 3 nodes rook
- openstack-helm-compute-kit-2024-1-ubuntu_jammy # 3 nodes