2
2
name : Test deployment and reimage on OpenStack
3
3
on :
4
4
workflow_dispatch :
5
- inputs :
6
- use_RL8 :
7
- required : true
8
- description : Include RL8 tests
9
- type : boolean
10
- default : false
11
5
push :
12
6
branches :
13
7
- main
@@ -20,22 +14,12 @@ jobs:
20
14
strategy :
21
15
matrix :
22
16
os_version : [RL8, RL9]
23
- rl8_selected :
24
- - ${{ inputs.use_RL8 == true }} # only potentially true for workflow_dispatch
25
- rl8_branch :
26
- - ${{ startsWith(github.head_ref, 'rl8') == true }} # only potentially for pull_request, always false on merge
27
- rl8_label :
28
- - ${{ contains(github.event.pull_request.labels.*.name, 'RL8') }} # NB: needs a new commit if added after PR created
29
- exclude :
30
- - os_version : RL8
31
- rl8_selected : false
32
- rl8_branch : false
33
- rl8_label : false
34
17
env :
35
18
ANSIBLE_FORCE_COLOR : True
36
19
OS_CLOUD : openstack
37
20
TF_VAR_cluster_name : slurmci-${{ matrix.os_version }}-${{ github.run_number }}
38
21
CI_CLOUD : ${{ vars.CI_CLOUD }}
22
+ TF_VAR_os_version : ${{ matrix.os_version }}
39
23
steps :
40
24
- uses : actions/checkout@v2
41
25
89
73
. environments/.stackhpc/activate
90
74
cd $APPLIANCES_ENVIRONMENT_ROOT/terraform
91
75
terraform apply -auto-approve -var-file="${{ vars.CI_CLOUD }}.tfvars"
92
- env :
93
- TF_VAR_os_version : ${{ matrix.os_version }}
94
76
95
77
- name : Delete infrastructure if provisioning failed
96
78
run : |
99
81
cd $APPLIANCES_ENVIRONMENT_ROOT/terraform
100
82
terraform destroy -auto-approve -var-file="${{ vars.CI_CLOUD }}.tfvars"
101
83
if : failure() && steps.provision_servers.outcome == 'failure'
102
- env :
103
- TF_VAR_os_version : ${{ matrix.os_version }}
104
84
105
85
- name : Configure cluster
106
86
run : |
@@ -199,8 +179,6 @@ jobs:
199
179
cd $APPLIANCES_ENVIRONMENT_ROOT/terraform
200
180
terraform destroy -auto-approve -var-file="${{ vars.CI_CLOUD }}.tfvars"
201
181
if : ${{ success() || cancelled() }}
202
- env :
203
- TF_VAR_os_version : ${{ matrix.os_version }}
204
182
205
183
# - name: Delete images
206
184
# run: |
0 commit comments