Skip to content

Commit

Permalink
Merge pull request #1443 from stackhpc/mn-minor-upgrade
Browse files Browse the repository at this point in the history
Add minor upgrade option to MN deploy workflow
  • Loading branch information
Alex-Welsh authored Jan 9, 2025
2 parents 63ef66f + cab8fa0 commit 41ba5ad
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/multinode-inputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class Scenario:
openstack_release: OpenStackRelease
os_release: OSRelease
neutron_plugin: str
upgrade: bool
upgrade: str


ROCKY_9 = OSRelease("rocky", "9", "cloud-user")
Expand All @@ -50,7 +50,7 @@ def random_scenario() -> Scenario:
openstack_release = random.choice(OPENSTACK_RELEASES)
os_release = random.choice(openstack_release.os_releases)
neutron_plugin = random.choice(NEUTRON_PLUGINS)
upgrade = random.random() > 0.6
upgrade = 'major' if random.random() > 0.6 else 'none'
return Scenario(openstack_release, os_release, neutron_plugin, upgrade)


Expand All @@ -62,7 +62,7 @@ def generate_inputs(scenario: Scenario) -> t.Dict[str, str]:
"os_release": scenario.os_release.release,
"ssh_username": scenario.os_release.ssh_username,
"neutron_plugin": scenario.neutron_plugin,
"upgrade": str(scenario.upgrade).lower(),
"upgrade": scenario.upgrade,
"stackhpc_kayobe_config_version": branch,
"stackhpc_kayobe_config_previous_version": previous_branch,
}
Expand Down
12 changes: 8 additions & 4 deletions .github/workflows/stackhpc-multinode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,12 @@ name: Multinode
- ovs
upgrade:
description: Whether to perform an upgrade
type: boolean
default: false
default: none
type: choice
options:
- none
- minor
- major
break_on:
description: When to break execution for manual interaction
type: choice
Expand All @@ -52,7 +56,7 @@ name: Multinode
jobs:
multinode:
name: Multinode
uses: stackhpc/stackhpc-openstack-gh-workflows/.github/workflows/multinode.yml@1.2.0
uses: stackhpc/stackhpc-openstack-gh-workflows/.github/workflows/multinode.yml@1.4.0
with:
multinode_name: ${{ inputs.multinode_name }}
os_distribution: ${{ inputs.os_distribution }}
Expand All @@ -66,6 +70,6 @@ jobs:
ssh_key: ${{ inputs.ssh_key }}
stackhpc_kayobe_config_version: ${{ github.ref_name }}
# NOTE(upgrade): Reference the PREVIOUS release here.
stackhpc_kayobe_config_previous_version: stackhpc/2023.1
stackhpc_kayobe_config_previous_version: ${{ inputs.upgrade == 'major' && 'stackhpc/2023.1' || 'stackhpc/2024.1' }}
terraform_kayobe_multinode_version: ${{ inputs.terraform_kayobe_multinode_version }}
secrets: inherit

0 comments on commit 41ba5ad

Please sign in to comment.