Skip to content

Changes for virtualization#28

Open
Mark-Powers wants to merge 37 commits intochameleoncloud/2023.1from
chameleoncloud/2023.1-kvm
Open

Changes for virtualization#28
Mark-Powers wants to merge 37 commits intochameleoncloud/2023.1from
chameleoncloud/2023.1-kvm

Conversation

@Mark-Powers
Copy link

@Mark-Powers Mark-Powers commented Jan 27, 2025

Not intended to merge, as this branch is incompatible with baremetal, but just to show a useful diff.

Main difference between baremetal is 99b59a6 which customizes the flavor selection panel of instance create To add description/gpu information.

Mark-Powers and others added 26 commits January 16, 2025 15:15
This adds extra UI in the images pane to show which images are official
Chameleon images and also allows users to publish images so that they
can be shared by other users -- this is accomplished using the 'sharing'
property already supported by Glance.
When using versionless Keystone endpoints in the service catalog (which
is the recommended way as it allows the client to do version selection),
region detection was broken. The reason is that a v3 suffix was
automatically added to the identity service URL before doing the region
detection. Region detection works by querying the service catalog for
which endpoint matches the Keystone auth URL used for the request. Since
the endpoint URL does not have a version suffix, the search will never
succeed, so the region defaults to None, and then later the first
endpoint is picked as a fallback behavior.

This fixes the check to also look for the original, unfixed URL when
trying to detect the region.
Make the placement API client respect the OPENSTACK_SSL_NO_VERIFY and
OPENSTACK_SSL_CACERT configuration options, so that it can work properly
in TLS-everywhere deployments.

Change-Id: Id0bb085bdf411eef240c3d50da56016c0a1d075c
(cherry picked from commit 1421234)
When endpoints don't have Keystone versions in them, region detection in
Horizon fails. This is such a pain in the ass at this point I don't have
much else to say.
This adds a toggle that allows an operator to disable the region
selector. This can be done by updating the configuration:

  OPENSTACK_KEYSTONE_MULTIREGION_SUPPORT = False
This adds a new way to render the top navigation. Instead of showing the
regions as dropdowns, instead show a list of Chameleon sites, fetched
from the reference API. This allows us to further obscure the
multi-region capabilities of Chameleon, with the aim of ultimately
removing them.

To opt-in to this functionality an operator can define:

  CHAMELEON_MULTISITE_SUPPORT = True

Additionally, the site ID needs to be specified. This needs to map to an
ID of a site in the reference API:

  CHAMELEON_SITE_ID = "tacc"

Finally, to disable the existing multi-region dropdown:

  OPENSTACK_KEYSTONE_MULTIREGION_SUPPORT = False

This only affects whether the UI is shown and doesn't modify any other
functionality/capabilities.
This isn't used in the default template that ships in Horizon, but we
may make use of it in a custom template.
Add /v3 to keystone endpoint url in app credential openrc template
We broadly have two classes of clouds now, baremetal and edge. Deep
links do not translate between the two b/c they have different services
set up, often. To avoid too many 404s but also assist users in switching sites,
only render deeplinks if linking b/w sites of the same class.
If Nova is not in the deployment (really only applies for a Zun-only
deployment like CHI@Edge), the floatingip UI will fail because it
makes calls to Nova. Instead, we should just swallow that error.
When the displayed quotas are overridden to only show one chart,
(such as showing instances, but not vcpu/memory under compute)
the "row" html tag was not closed.

While this could be fixed by removing the check for "forloop.first" in
the closing bounds check, a more robust fix seems to be moving the row
open/close tags outside of the loop entirely.

Those checks were only in place to generate a new row every 6 columns,
but that is now handled by the bootstrap column spec instead, so we can
unconitionally generate a row for each section, and let bootstrap handle
rendering/wrapping of the columns.
our logic to set the default flavor if only one is defined had the
potential to bypass the flavor validation logic. to resolve this, it was
moved outwards from the "build" to "update" method, and now checks the
"enabled" property, which is set after validation.

Additionally, logic was adjusted for the validation method, which would
raise errors when allocation flavor was set programatically, as the form
was not yet initialized.
in the instance launch dialog, allow configuration of default selected
flavor. To do so, set `default_flavor_name` in the `LAUNCH_INSTANCE_DEFAULTS`
configuration dict.
This reverts commit 100e80a.
Unsure why, but it breaks container creation in 2023.1+
@msherman64
Copy link

msherman64 commented Feb 10, 2025

@Mark-Powers do you see an issue with, (for a while), maintaining this as a kvm-only branch?

As we still have not made the bare-metal only features toggle-able via config

although we'd probably have a smaller diff against chameleoncloud/2023.1, I'm unsure why some of the reverts are in this list when based against stable/2023.1

@Mark-Powers Mark-Powers changed the base branch from stable/2023.1 to chameleoncloud/2023.1 February 11, 2025 14:39
@Mark-Powers
Copy link
Author

@msherman64 Yes, I mentioned in the description, but we'll need to maintain this as it's own branch for now. I just made this PR to show the diff mainly

@profiler.trace
@memoized.memoized
def flavor_list(request, is_public=True, get_extras=False):
def flavor_list(request, is_public=True, get_extras=False, detailed=False):

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

flavor_list defaults to detailed=True, setting it to False here breaks default behavior for the instances table.

additionally, memoized is removed now?

the default behavior for `flavor_list` is to include details. Setting the default to false breaks the table in project/instances.
These flavors should really only be seen by blazar, not the end user
@msherman64 msherman64 force-pushed the chameleoncloud/2023.1 branch 2 times, most recently from 291cb0e to a14bf37 Compare May 29, 2025 16:16
@Mark-Powers
Copy link
Author

Notes on latest commit 6a08391

Takes all of our baremetal changes and puts them behind CHAMELEON_BAREMETAL_ONLY setting. This is propagated to the JS code via a wrapper for the built in horizon settings service.

If set, this toggles everything to "baremetal mode", meaning we remove things that aren't functional/useful in baremetal. It's meant to be set only when we are using baremetal only. In the future when we have both, we will need a few more tweaks to the instance launch dialog to pick lease id or flavor.

This ended up being the 3rd iteration of the config, and it is the most reliable option I could find. The keypair tab already uses the settings API, so it shouldn't really slow anything down.

@Mark-Powers Mark-Powers requested review from msherman64 and pdmars and removed request for msherman64 and pdmars February 11, 2026 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants