diff --git a/scripts/include.sh b/scripts/include.sh index f94604fb9..108580ea2 100644 --- a/scripts/include.sh +++ b/scripts/include.sh @@ -25,6 +25,28 @@ sync_inventory() { fi } +# Move the manager service to MANAGER_VERSION, picking the entry point the +# target release actually ships. +# +# run.sh runs the manager play from the configuration repository and selects the +# osism/seed container by itself, but only from osism/generics v0.20260627.0 on. +# gilt.yml is pinned to the target release's generics_version by set-versions.py, +# so a release pinning an older generics delivers a run.sh that knows no +# container path and builds a local Ansible venv instead. Up to and including +# 10.1.0 (generics v0.20260615.0) that is every release, and all of them still +# ship the osism-update-manager wrapper, so use it there. +# +# ansible-collection-services#2154 removes that wrapper; the removal is in the +# collection from v0.20260806.0 on and no release pins it yet. Releases cut from +# here on carry both changes, so the newer branch is the one that stays. +update_manager() { + if [[ $(semver $MANAGER_VERSION 10.1.0) -gt 0 || $MANAGER_VERSION == "latest" ]]; then + /opt/configuration/environments/manager/run.sh manager + else + osism update manager + fi +} + # Select the key-value store service for the active OpenStack release. Upstream # kolla-ansible replaced redis with valkey at 2025.2; older releases still ship # redis. The release is read from the kolla-ansible image label. diff --git a/scripts/upgrade-ceph.sh b/scripts/upgrade-ceph.sh index 93628dda4..018cda83a 100755 --- a/scripts/upgrade-ceph.sh +++ b/scripts/upgrade-ceph.sh @@ -26,9 +26,7 @@ fi sh -c '/opt/configuration/scripts/sync-configuration-repository.sh' # upgrade manager -# See the note in upgrade-manager.sh: the manager play is run from the -# configuration repository instead of via `osism update manager`. -/opt/configuration/environments/manager/run.sh manager +update_manager docker compose --project-directory /opt/manager ps # refresh facts & sync the inventory diff --git a/scripts/upgrade-manager.sh b/scripts/upgrade-manager.sh index ded3f7ad7..0855a0d6e 100755 --- a/scripts/upgrade-manager.sh +++ b/scripts/upgrade-manager.sh @@ -68,11 +68,7 @@ if [[ $MANAGER_UPGRADE_CROSSES_10 == "true" || $OPENSTACK_UPGRADE_CROSSES_2025 = fi # upgrade manager -# Run the manager play from the configuration repository, as the upgrade guide -# describes it for a manager without a local Ansible venv. This replaces -# `osism update manager`, whose wrapper script is being removed in -# ansible-collection-services#2154. -/opt/configuration/environments/manager/run.sh manager +update_manager # wait for manager service wait_for_container_healthy 60 ceph-ansible