81
81
uses : ConorMacBride/install-package@main
82
82
with :
83
83
apt : build-essential git unzip nodejs python3 python3-pip python3-wheel python-is-python3
84
- if : ${{ !cancelled() }}
85
84
86
85
- uses : actions/checkout@v4
87
86
with :
@@ -90,13 +89,13 @@ jobs:
90
89
- name : Make sure dockerd is running and test Docker.
91
90
run : |
92
91
docker run --rm hello-world
93
- if : ${{ !cancelled() }}
92
+
94
93
95
94
- name : Output image tag
96
95
id : image_tag
97
96
run : |
98
97
echo image_tag=$(grep stackhpc_${{ inputs.os_distribution }}_$(sed s/-/_/ <(echo "${{ inputs.os_release }}"))_overcloud_host_image_version: etc/kayobe/pulp-host-image-versions.yml | awk '{print $2}') >> $GITHUB_OUTPUT
99
- if : ${{ !cancelled() }}
98
+
100
99
101
100
# Use the image override if set, otherwise use overcloud-os_distribution-os_release-tag
102
101
- name : Output image name
@@ -107,29 +106,29 @@ jobs:
107
106
else
108
107
echo image_name=${{ inputs.vm_image_override }} >> $GITHUB_OUTPUT
109
108
fi
110
- if : ${{ !cancelled() }}
109
+
111
110
112
111
- name : Install terraform
113
112
uses : hashicorp/setup-terraform@v2
114
- if : ${{ !cancelled() }}
113
+
115
114
116
115
- name : Initialise terraform
117
116
run : terraform init
118
117
working-directory : ${{ github.workspace }}/terraform/aio
119
- if : ${{ !cancelled() }}
118
+
120
119
121
120
- name : Generate SSH keypair
122
121
run : ssh-keygen -f id_rsa -N ''
123
122
working-directory : ${{ github.workspace }}/terraform/aio
124
- if : ${{ !cancelled() }}
123
+
125
124
126
125
- name : Generate clouds.yaml
127
126
run : |
128
127
cat << EOF > clouds.yaml
129
128
${{ secrets.CLOUDS_YAML }}
130
129
EOF
131
130
working-directory : ${{ github.workspace }}/terraform/aio
132
- if : ${{ !cancelled() }}
131
+
133
132
134
133
- name : Generate terraform.tfvars
135
134
run : |
@@ -152,7 +151,7 @@ jobs:
152
151
VM_NETWORK : ${{ inputs.vm_network }}
153
152
VM_SUBNET : ${{ inputs.vm_subnet }}
154
153
VM_INTERFACE : ${{ inputs.vm_interface }}
155
- if : ${{ !cancelled() }}
154
+
156
155
157
156
- name : Terraform Plan
158
157
run : terraform plan
@@ -161,7 +160,7 @@ jobs:
161
160
OS_CLOUD : ${{ inputs.OS_CLOUD }}
162
161
OS_APPLICATION_CREDENTIAL_ID : ${{ secrets.OS_APPLICATION_CREDENTIAL_ID }}
163
162
OS_APPLICATION_CREDENTIAL_SECRET : ${{ secrets.OS_APPLICATION_CREDENTIAL_SECRET }}
164
- if : ${{ !cancelled() }}
163
+
165
164
166
165
- name : Terraform Apply
167
166
run : terraform apply -auto-approve
@@ -170,21 +169,21 @@ jobs:
170
169
OS_CLOUD : ${{ inputs.OS_CLOUD }}
171
170
OS_APPLICATION_CREDENTIAL_ID : ${{ secrets.OS_APPLICATION_CREDENTIAL_ID }}
172
171
OS_APPLICATION_CREDENTIAL_SECRET : ${{ secrets.OS_APPLICATION_CREDENTIAL_SECRET }}
173
- if : ${{ !cancelled() }}
172
+
174
173
175
174
- name : Get Terraform outputs
176
175
id : tf_outputs
177
176
run : |
178
177
terraform output -json
179
178
working-directory : ${{ github.workspace }}/terraform/aio
180
- if : ${{ !cancelled() }}
179
+
181
180
182
181
- name : Write Terraform outputs
183
182
run : |
184
183
cat << EOF > etc/kayobe/environments/$KAYOBE_ENVIRONMENT/tf-outputs.yml
185
184
${{ steps.tf_outputs.outputs.stdout }}
186
185
EOF
187
- if : ${{ !cancelled() }}
186
+
188
187
189
188
- name : Write Terraform network config
190
189
run : |
@@ -199,14 +198,14 @@ jobs:
199
198
admin_ips:
200
199
controller0: "{{ access_ip_v4.value }}"
201
200
EOF
202
- if : ${{ !cancelled() }}
201
+
203
202
204
203
- name : Write Terraform network interface config
205
204
run : |
206
205
cat << EOF > etc/kayobe/environments/$KAYOBE_ENVIRONMENT/inventory/group_vars/controllers/tf-network-interfaces
207
206
admin_interface: "{{ access_interface.value }}"
208
207
EOF
209
- if : ${{ !cancelled() }}
208
+
210
209
211
210
- name : Write all-in-one scenario config
212
211
run : |
@@ -220,7 +219,7 @@ jobs:
220
219
ENABLE_OVN : ${{ inputs.neutron_plugin == 'ovn' }}
221
220
OS_DISTRIBUTION : ${{ inputs.os_distribution }}
222
221
OS_RELEASE : ${{ inputs.os_release }}
223
- if : ${{ !cancelled() }}
222
+
224
223
225
224
# Use a heredoc to define a multiline string output
226
225
# https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#multiline-strings
@@ -230,13 +229,13 @@ jobs:
230
229
echo "ssh_key<<EOF" >> $GITHUB_OUTPUT
231
230
cat terraform/aio/id_rsa >> $GITHUB_OUTPUT
232
231
echo "EOF" >> $GITHUB_OUTPUT
233
- if : ${{ !cancelled() }}
232
+
234
233
235
234
# The same tag may be reused (e.g. pr-123), so ensure we have the latest image.
236
235
- name : Pull latest Kayobe image
237
236
run : |
238
237
docker image pull $KAYOBE_IMAGE
239
- if : ${{ !cancelled() }}
238
+
240
239
241
240
- name : Run growroot
242
241
run : |
@@ -247,7 +246,7 @@ jobs:
247
246
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/playbook-run.sh '$KAYOBE_CONFIG_PATH/ansible/growroot.yml'
248
247
env :
249
248
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY : ${{ steps.ssh_key.outputs.ssh_key }}
250
- if : ${{ !cancelled() }}
249
+
251
250
252
251
- name : Host configure
253
252
run : |
@@ -258,7 +257,7 @@ jobs:
258
257
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/overcloud-host-configure.sh
259
258
env :
260
259
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY : ${{ steps.ssh_key.outputs.ssh_key }}
261
- if : ${{ !cancelled() }}
260
+
262
261
263
262
- name : Service deploy
264
263
run : |
@@ -269,7 +268,7 @@ jobs:
269
268
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/overcloud-service-deploy.sh
270
269
env :
271
270
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY : ${{ steps.ssh_key.outputs.ssh_key }}
272
- if : ${{ !cancelled() }}
271
+
273
272
274
273
- name : Configure aio resources
275
274
run : |
@@ -280,7 +279,7 @@ jobs:
280
279
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/playbook-run.sh etc/kayobe/ansible/configure-aio-resources.yml
281
280
env :
282
281
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY : ${{ steps.ssh_key.outputs.ssh_key }}
283
- if : ${{ !cancelled() }}
282
+
284
283
285
284
286
285
- name : Tempest tests
@@ -294,7 +293,7 @@ jobs:
294
293
/stack/kayobe-automation-env/src/kayobe-config/.automation/pipeline/tempest.sh -e ansible_user=stack
295
294
env :
296
295
KAYOBE_AUTOMATION_SSH_PRIVATE_KEY : ${{ steps.ssh_key.outputs.ssh_key }}
297
- if : ${{ !cancelled() }}
296
+
298
297
299
298
- name : Upload test result artifacts
300
299
uses : actions/upload-artifact@v4
0 commit comments