Skip to content

Commit

Permalink
Fix default volume type configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
electrocucaracha committed Aug 21, 2024
1 parent 83ce5b3 commit 8ca2d9e
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 2 deletions.
2 changes: 2 additions & 0 deletions etc/kolla/config/cinder/cinder-api.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[DEFAULT]
default_volume_type = lvm-1
2 changes: 2 additions & 0 deletions etc/kolla/config/cinder/cinder-volume.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[DEFAULT]
default_volume_type = lvm-1
2 changes: 0 additions & 2 deletions etc/kolla/config/cinder/cinder.conf

This file was deleted.

1 change: 1 addition & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ if [ "${OS_KOLLA_RUN_INIT:-true}" == "true" ]; then
source /etc/kolla/admin-openrc.sh
curl -fsSL "https://raw.githubusercontent.com/openstack/kolla-ansible/${OS_KOLLA_VERSION:-stable/2024.1}/tools/init-runonce" | bash

[ "${OS_KOLLA_ENABLE_CINDER:-yes}" == "yes" ] && ./scripts/cinder.sh
[ "${OS_KOLLA_ENABLE_MAGNUM:-no}" == "yes" ] && ./scripts/magnum.sh
[ "${OS_KOLLA_ENABLE_NEUTRON_TRUNK:-yes}" == "yes" ] && ./scripts/neutron_trunk.sh
fi
Expand Down
24 changes: 24 additions & 0 deletions scripts/cinder.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash
# SPDX-license-identifier: Apache-2.0
##############################################################################
# Copyright (c) 2024
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################

set -o nounset
set -o pipefail
set -o errexit
if [[ ${OS_DEBUG:-false} == "true" ]]; then
export PKG_DEBUG=true
set -o xtrace
fi

os_cinder_volume_type="lvm-1"

if ! openstack volume type list | grep -q "$os_cinder_volume_type"; then
openstack volume type create "$os_cinder_volume_type" \
--property volume_backend_name="$os_cinder_volume_type"
fi

0 comments on commit 8ca2d9e

Please sign in to comment.