Comment 3 for bug 1989538

Revision history for this message
Alex Kavanagh (ajkavanagh) wrote : Re: keystone bootstrap fail on latest/edge

So the reason is breaks is that during the install hook, the /etc/openstack-release file from the openstack-release package is installed from distro (e.g. jammy) and not the jammy-zed cloud-archive.

The initial call to `configure_installation_source` causes the openstack-release package to be installed **before** the cloud archive apt sources are configured (just tracing through the calls), which means it gets the distro version of openstack-release. Then it's cached for the remainder of the install hook. Then, during config-changed, the charm sees the 'wrong' version is installed and tries to do the upgrade which breaks.

The solution is probably either:

1. break or skip the caching in charmhelpers/contrib/openstack/utils.py:get_os_installed_version() for the initial check; maybe using a no_install parameter or similar to get around the issue.
2. Force a re-installation of the openstack-release package after the sources have been configured so that it's at the right version.

Either way, it's a bit broken.