Skip to content

Commit 0063621

Browse files
committed
Use system scope when running baremetal tests
Starting with 2024.1, some actions no longer work with a project scoped token.
1 parent 2d11163 commit 0063621

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

.github/workflows/functional-baremetal.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,20 @@ jobs:
1313
name: ["master"]
1414
openstack_version: ["master"]
1515
ubuntu_version: ["22.04"]
16+
os_system_scope: ["all"]
1617
include:
1718
- name: "bobcat"
1819
openstack_version: "stable/2023.2"
1920
ubuntu_version: "22.04"
21+
os_system_scope: ""
2022
- name: "antelope"
2123
openstack_version: "stable/2023.1"
2224
ubuntu_version: "22.04"
25+
os_system_scope: ""
2326
- name: "zed"
2427
openstack_version: "stable/zed"
2528
ubuntu_version: "20.04"
29+
os_system_scope: ""
2630
runs-on: ubuntu-${{ matrix.ubuntu_version }}
2731
name: Deploy OpenStack ${{ matrix.name }} with Ironic and run baremetal acceptance tests
2832
steps:
@@ -88,6 +92,8 @@ jobs:
8892
DEVSTACK_PATH: ${{ github.workspace }}/devstack
8993
ACCEPTANCE_TESTS_FILTER: '^.*baremetal(.(?!noauth).*)?$'
9094
OS_BRANCH: ${{ matrix.openstack_version }}
95+
# TODO(dtantsur): default to "all" when no longer supporting versions before 2024.1
96+
OS_SYSTEM_SCOPE: ${{ matrix.os_system_scope }}
9197
- name: Generate logs on failure
9298
run: ./script/collectlogs
9399
if: failure()

script/stackenv

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,8 @@ echo export OS_DOMAIN_ID=default >> openrc
3030
echo export OS_MAGNUM_IMAGE_ID="$_MAGNUM_IMAGE_ID" >> openrc
3131
echo export OS_MAGNUM_KEYPAIR=magnum >> openrc
3232
source openrc admin admin
33+
if [[ "${OS_SYSTEM_SCOPE:-}" == "all" ]]; then
34+
unset PROJECT_NAME
35+
unset TENANT_NAME
36+
fi
3337
popd

0 commit comments

Comments
 (0)