@@ -20,6 +20,7 @@ permissions:
20
20
env :
21
21
AWS_REGION : " eu-central-1"
22
22
SSH_AUTH_SOCK : /tmp/ssh_agent.sock
23
+ STAGING_PREVIEW_SERVICES_HOST : staging-preview-services-service.staging-preview.svc.cluster.local
23
24
STAGING_PREVIEW_VALIDATOR_1_HOST : staging-preview-validator-1-service.staging-preview.svc.cluster.local
24
25
STAGING_PREVIEW_VALIDATOR_1_PORT : 9933
25
26
@@ -176,7 +177,13 @@ jobs:
176
177
partner-chain-ready :
177
178
runs-on : [self-hosted, eks]
178
179
needs : deploy-staging-preview
180
+ outputs :
181
+ deployment_mc_epoch : ${{ steps.mc-epoch.outputs.deployment_mc_epoch }}
179
182
steps :
183
+ - name : Set deployment main chain epoch
184
+ id : mc-epoch
185
+ run : echo "deployment_mc_epoch=$(curl -s http://$STAGING_PREVIEW_SERVICES_HOST:1337/health | jq .currentEpoch)" >> $GITHUB_OUTPUT
186
+ shell : bash
180
187
- name : Check Finalization Status
181
188
run : |
182
189
FINALIZED_NUMBER=$(
@@ -204,9 +211,6 @@ jobs:
204
211
uses : actions/checkout@v4
205
212
- name : Configure kubectl
206
213
uses : ./.github/actions/tests/staging-preview-tests
207
- with :
208
- node-host : $STAGING_PREVIEW_VALIDATOR_1_HOST
209
- node-port : $STAGING_PREVIEW_VALIDATOR_1_PORT
210
214
env :
211
215
kubeconfig_base64 : ${{ secrets.kubeconfig_base64 }}
212
216
K8S_SERVER : ${{ secrets.K8S_SERVER }}
@@ -234,9 +238,6 @@ jobs:
234
238
uses : actions/checkout@v4
235
239
- name : Configure kubectl
236
240
uses : ./.github/actions/tests/staging-preview-tests
237
- with :
238
- node-host : $STAGING_PREVIEW_VALIDATOR_1_HOST
239
- node-port : $STAGING_PREVIEW_VALIDATOR_1_PORT
240
241
env :
241
242
kubeconfig_base64 : ${{ secrets.kubeconfig_base64 }}
242
243
K8S_SERVER : ${{ secrets.K8S_SERVER }}
@@ -245,18 +246,16 @@ jobs:
245
246
uses : ./.github/actions/tests/setup-python
246
247
env :
247
248
ACTIONS_PAT : ${{ secrets.ACTIONS_PAT }}
248
- - name : Save deployment main chain epoch
249
- run : |
250
- echo "DEPLOYMENT_MC_EPOCH=$(curl -s http://staging-preview-services-service.staging-preview.svc.cluster.local:1337/health | jq .currentEpoch)" >> $GITHUB_ENV
251
- shell : bash
252
249
- name : Run all tests (some skipped due to new deployment)
253
250
uses : ./.github/actions/tests/run-e2e-tests
251
+ env :
252
+ DEPLOYMENT_MC_EPOCH : ${{needs.partner-chain-ready.outputs.deployment_mc_epoch}}
254
253
with :
255
254
blockchain : substrate
256
255
env : staging
257
256
decrypt : true
258
257
markers : " not active_flow and not passive_flow"
259
- deployment_mc_epoch : ${{ env. DEPLOYMENT_MC_EPOCH }}
258
+ deployment_mc_epoch : $DEPLOYMENT_MC_EPOCH
260
259
261
260
wait-for-next-epoch :
262
261
permissions :
@@ -269,15 +268,17 @@ jobs:
269
268
uses : actions/checkout@v4
270
269
- name : Set MC epoch to wait for
271
270
id : increment-epoch
271
+ env :
272
+ DEPLOYMENT_MC_EPOCH : ${{needs.partner-chain-ready.outputs.deployment_mc_epoch}}
272
273
run : |
273
274
echo "Current epoch: $DEPLOYMENT_MC_EPOCH"
274
275
incremented_epoch=$((DEPLOYMENT_MC_EPOCH + 1))
275
276
echo "Incremented epoch: $incremented_epoch"
276
- echo "::set-output name=epoch:: $incremented_epoch"
277
+ echo "mc_epoch_to_wait_for= $incremented_epoch" >> $GITHUB_OUTPUT
277
278
- name : Wait for next MC epoch
278
279
uses : ./.github/actions/tests/wait-for-epoch
279
280
with :
280
- epoch : ${{ steps.increment-epoch.outputs.epoch }}"
281
+ epoch : ${{ steps.increment-epoch.outputs.mc_epoch_to_wait_for }}"
281
282
deployment : kubernetes
282
283
node : staging-preview-validator-1
283
284
environment : staging-preview
@@ -293,9 +294,6 @@ jobs:
293
294
uses : actions/checkout@v4
294
295
- name : Configure kubectl
295
296
uses : ./.github/actions/tests/staging-preview-tests
296
- with :
297
- node-host : $STAGING_PREVIEW_VALIDATOR_1_HOST
298
- node-port : $STAGING_PREVIEW_VALIDATOR_1_PORT
299
297
env :
300
298
kubeconfig_base64 : ${{ secrets.kubeconfig_base64 }}
301
299
K8S_SERVER : ${{ secrets.K8S_SERVER }}
@@ -306,13 +304,15 @@ jobs:
306
304
ACTIONS_PAT : ${{ secrets.ACTIONS_PAT }}
307
305
- name : Run all tests (some skipped due to new deployment)
308
306
uses : ./.github/actions/tests/run-e2e-tests
307
+ env :
308
+ DEPLOYMENT_MC_EPOCH : ${{needs.partner-chain-ready.outputs.deployment_mc_epoch}}
309
309
with :
310
310
blockchain : substrate
311
311
env : staging
312
312
decrypt : true
313
313
latest_mc_epoch : true
314
314
markers : " not active_flow and not passive_flow"
315
- deployment_mc_epoch : ${{ env. DEPLOYMENT_MC_EPOCH }}
315
+ deployment_mc_epoch : $DEPLOYMENT_MC_EPOCH
316
316
317
317
# build-and-publish-ghcr:
318
318
# permissions:
0 commit comments