Sync/rebuild for Dalmatian/Epoxy updates
Refresh and rebuild charm for awareness of Dalmatian and Epoxy Cloud Archive releases. Change-Id: I1489f2a55b21f8b22ef7d017d7a2b1e84a748f78
This commit is contained in:
@@ -162,6 +162,8 @@ OPENSTACK_CODENAMES = OrderedDict([
|
||||
('2023.1', 'antelope'),
|
||||
('2023.2', 'bobcat'),
|
||||
('2024.1', 'caracal'),
|
||||
('2024.2', 'dalmatian'),
|
||||
('2025.1', 'epoxy'),
|
||||
])
|
||||
|
||||
# The ugly duckling - must list releases oldest to newest
|
||||
|
||||
@@ -18,7 +18,10 @@
|
||||
# Charm Helpers Developers <juju@lists.ubuntu.com>
|
||||
|
||||
import copy
|
||||
from distutils.version import LooseVersion
|
||||
try:
|
||||
from distutils.version import LooseVersion
|
||||
except ImportError:
|
||||
from looseversion import LooseVersion
|
||||
from enum import Enum
|
||||
from functools import wraps
|
||||
from collections import namedtuple, UserDict
|
||||
|
||||
@@ -254,6 +254,22 @@ CLOUD_ARCHIVE_POCKETS = {
|
||||
'caracal/proposed': 'jammy-proposed/caracal',
|
||||
'jammy-caracal/proposed': 'jammy-proposed/caracal',
|
||||
'jammy-proposed/caracal': 'jammy-proposed/caracal',
|
||||
# dalmatian
|
||||
'dalmatian': 'noble-updates/dalmatian',
|
||||
'noble-dalmatian': 'noble-updates/dalmatian',
|
||||
'noble-dalmatian/updates': 'noble-updates/dalmatian',
|
||||
'noble-updates/dalmatian': 'noble-updates/dalmatian',
|
||||
'dalmatian/proposed': 'noble-proposed/dalmatian',
|
||||
'noble-dalmatian/proposed': 'noble-proposed/dalmatian',
|
||||
'noble-proposed/dalmatian': 'noble-proposed/dalmatian',
|
||||
# epoxy
|
||||
'epoxy': 'noble-updates/epoxy',
|
||||
'noble-epoxy': 'noble-updates/epoxy',
|
||||
'noble-epoxy/updates': 'noble-updates/epoxy',
|
||||
'noble-updates/epoxy': 'noble-updates/epoxy',
|
||||
'epoxy/proposed': 'noble-proposed/epoxy',
|
||||
'noble-epoxy/proposed': 'noble-proposed/epoxy',
|
||||
'noble-proposed/epoxy': 'noble-proposed/epoxy',
|
||||
|
||||
# OVN
|
||||
'focal-ovn-22.03': 'focal-updates/ovn-22.03',
|
||||
@@ -288,6 +304,8 @@ OPENSTACK_RELEASES = (
|
||||
'antelope',
|
||||
'bobcat',
|
||||
'caracal',
|
||||
'dalmatian',
|
||||
'epoxy',
|
||||
)
|
||||
|
||||
|
||||
@@ -318,6 +336,8 @@ UBUNTU_OPENSTACK_RELEASE = OrderedDict([
|
||||
('lunar', 'antelope'),
|
||||
('mantic', 'bobcat'),
|
||||
('noble', 'caracal'),
|
||||
('oracular', 'dalmatian'),
|
||||
('plucky', 'epoxy'),
|
||||
])
|
||||
|
||||
|
||||
|
||||
@@ -695,7 +695,7 @@ def get_crimson_osd_ids():
|
||||
|
||||
|
||||
def get_local_osd_ids():
|
||||
"""This will list the /var/lib/ceph/osd/ceph-* directories and try
|
||||
"""This will list the /var/lib/ceph/osd/* directories and try
|
||||
to split the ID off of the directory name and return it in
|
||||
a list. Excludes crimson OSD's from the returned list.
|
||||
|
||||
@@ -704,18 +704,19 @@ def get_local_osd_ids():
|
||||
"""
|
||||
osd_ids = []
|
||||
crimson_osds = get_crimson_osd_ids()
|
||||
osd_path = '/var/lib/ceph/osd'
|
||||
osd_path = os.path.join(os.sep, 'var', 'lib', 'ceph', 'osd')
|
||||
if os.path.exists(osd_path):
|
||||
dirs = [d for d in os.listdir(osd_path)
|
||||
if d.startswith('ceph-')
|
||||
and os.path.isdir(os.path.join(osd_path, d))]
|
||||
for osd_dir in dirs:
|
||||
osd_id = osd_dir.split('-', maxsplit=1)[1]
|
||||
if (_is_int(osd_id) and
|
||||
filesystem_mounted(os.path.join(
|
||||
osd_path, osd_dir)) and
|
||||
osd_id not in crimson_osds):
|
||||
osd_ids.append(osd_id)
|
||||
try:
|
||||
dirs = os.listdir(osd_path)
|
||||
for osd_dir in dirs:
|
||||
osd_id = osd_dir.split('-')[1] if '-' in osd_dir else ''
|
||||
if (_is_int(osd_id) and
|
||||
filesystem_mounted(os.path.join(
|
||||
os.sep, osd_path, osd_dir)) and
|
||||
osd_id not in crimson_osds):
|
||||
osd_ids.append(osd_id)
|
||||
except OSError:
|
||||
raise
|
||||
return osd_ids
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user