@@ -9,16 +9,19 @@ permissions:
99 id-token : write
1010 contents : read
1111
12- # One resource group is shared by every job in this run, so serialize runs to
13- # avoid one run tearing down another's group.
12+ # Each run provisions its own uniquely-named resource group (suffixed with the
13+ # run id), so concurrent runs on different branches/PRs never collide or tear
14+ # down each other's group. The concurrency group is branch-scoped only to avoid
15+ # piling up runs on rapid pushes to the same ref - it does NOT serialize across
16+ # the whole repo, so an unapproved run on one PR can never block another.
1417concurrency :
15- group : azure-login-live-tests
18+ group : azure-login-live-tests-${{ github.ref }}
1619 cancel-in-progress : false
1720
1821env :
1922 # Created once in setup; the positive and embedded "can access" assertions
20- # target this group.
21- RG_POSITIVE : GitHubAction_CI_Group
23+ # target this group. Suffixed with the run id so every run is isolated.
24+ RG_POSITIVE : GitHubAction_CI_Group_${{ github.run_id }}
2225 LOCATION : eastus
2326 # Intentionally NEVER created: the negative permission/not-found assertions
2427 # target this name so they fail as expected.
3841 with :
3942 creds : ${{ secrets.PROVISION_CREDS }}
4043 - name : Create resource group
41- run : az group create --name "$RG_POSITIVE" --location "$LOCATION" --output none
44+ run : az group create --name "${{ env. RG_POSITIVE }} " --location "${{ env. LOCATION }} " --output none
4245
4346 # ================================================================ POSITIVE
4447 Positive_BasicTest :
@@ -52,10 +55,10 @@ jobs:
5255
5356 steps :
5457 - name : ' Checking out repo code'
55- uses : actions/checkout@v6
58+ uses : actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
5659
5760 - name : Set Node.js 24.x for GitHub Action
58- uses : actions/setup-node@v6
61+ uses : actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
5962 with :
6063 node-version : 24.x
6164
7780 - name : Run Azure Cli
7881 run : |
7982 az account show --output none
80- az group show --name GitHubAction_CI_Group --output none
83+ az group show --name "${{ env.RG_POSITIVE }}" --output none
8184
8285 - name : Run Azure PowerShell
8386 uses : azure/powershell@v3
@@ -121,7 +124,7 @@ jobs:
121124 - name : Run Azure Cli
122125 run : |
123126 az account show --output none
124- az group show --name GitHubAction_CI_Group --output none
127+ az group show --name "${{ env.RG_POSITIVE }}" --output none
125128
126129 - name : Run Azure PowerShell
127130 uses : azure/powershell@v3
@@ -144,10 +147,10 @@ jobs:
144147
145148 steps :
146149 - name : ' Checking out repo code'
147- uses : actions/checkout@v6
150+ uses : actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
148151
149152 - name : Set Node.js 24.x for GitHub Action
150- uses : actions/setup-node@v6
153+ uses : actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
151154 with :
152155 node-version : 24.x
153156
@@ -165,7 +168,7 @@ jobs:
165168 - name : Run Azure Cli
166169 run : |
167170 az account show --output none
168- az group show --name GitHubAction_CI_Group --output none
171+ az group show --name "${{ env.RG_POSITIVE }}" --output none
169172
170173 - name : Login with creds, wrong boolean value
171174 uses : ./
@@ -176,7 +179,7 @@ jobs:
176179 - name : Run Azure Cli
177180 run : |
178181 az account show --output none
179- az group show --name GitHubAction_CI_Group --output none
182+ az group show --name "${{ env.RG_POSITIVE }}" --output none
180183
181184 - name : Login with creds, allow no subscription
182185 uses : ./
@@ -188,7 +191,7 @@ jobs:
188191 - name : Run Azure Cli
189192 run : |
190193 az account show --output none
191- az group show --name GitHubAction_CI_Group --output none
194+ az group show --name "${{ env.RG_POSITIVE }}" --output none
192195
193196 - name : Run Azure PowerShell
194197 uses : azure/powershell@v3
@@ -277,10 +280,10 @@ jobs:
277280 environment : Automation test
278281 steps :
279282 - name : ' Checking out repo code'
280- uses : actions/checkout@v6
283+ uses : actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
281284
282285 - name : Set Node.js 24.x for GitHub Action
283- uses : actions/setup-node@v6
286+ uses : actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
284287 with :
285288 node-version : 24.x
286289
@@ -360,10 +363,10 @@ jobs:
360363 steps :
361364
362365 - name : ' Checking out repo code'
363- uses : actions/checkout@v6
366+ uses : actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
364367
365368 - name : Set Node.js 24.x for GitHub Action
366- uses : actions/setup-node@v6
369+ uses : actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
367370 with :
368371 node-version : 24.x
369372
@@ -390,7 +393,7 @@ jobs:
390393
391394 - name : Check Last step failed
392395 if : steps.cli_3.outcome == 'success'
393- uses : actions/github-script@v7
396+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
394397 with :
395398 script : |
396399 core.setFailed('Last action should fail but not. Please check it.')
@@ -407,7 +410,7 @@ jobs:
407410
408411 - name : Check Last step failed
409412 if : steps.ps_3.outcome == 'success'
410- uses : actions/github-script@v7
413+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
411414 with :
412415 script : |
413416 core.setFailed('Last action should fail but not. Please check it.')
@@ -423,10 +426,10 @@ jobs:
423426
424427 steps :
425428 - name : ' Checking out repo code'
426- uses : actions/checkout@v6
429+ uses : actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
427430
428431 - name : Set Node.js 24.x for GitHub Action
429- uses : actions/setup-node@v6
432+ uses : actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
430433 with :
431434 node-version : 24.x
432435
@@ -445,7 +448,7 @@ jobs:
445448
446449 - name : Check Last step failed
447450 if : steps.login_4.outcome == 'success'
448- uses : actions/github-script@v7
451+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
449452 with :
450453 script : |
451454 core.setFailed('Last action should fail but not. Please check it.')
@@ -460,7 +463,7 @@ jobs:
460463
461464 - name : Check Last step failed
462465 if : steps.login_5.outcome == 'success'
463- uses : actions/github-script@v7
466+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
464467 with :
465468 script : |
466469 core.setFailed('Last action should fail but not. Please check it.')
@@ -474,7 +477,7 @@ jobs:
474477
475478 - name : Check Last step failed
476479 if : steps.login_6.outcome == 'success'
477- uses : actions/github-script@v7
480+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
478481 with :
479482 script : |
480483 core.setFailed('Last action should fail but not. Please check it.')
@@ -490,7 +493,7 @@ jobs:
490493
491494 - name : Check Last step failed
492495 if : steps.login_7.outcome == 'success'
493- uses : actions/github-script@v7
496+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
494497 with :
495498 script : |
496499 core.setFailed('Last action should fail but not. Please check it.')
@@ -507,7 +510,7 @@ jobs:
507510
508511 - name : Check Last step failed
509512 if : steps.login_8.outcome == 'success'
510- uses : actions/github-script@v7
513+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
511514 with :
512515 script : |
513516 core.setFailed('Last action should fail but not. Please check it.')
@@ -521,7 +524,7 @@ jobs:
521524 - name : Run Azure Cli
522525 run : |
523526 az account show --output none
524- az group show --name GitHubAction_CI_Group --output none
527+ az group show --name "${{ env.RG_POSITIVE }}" --output none
525528
526529 - name : Run Azure PowerShell
527530 id : ps_8
@@ -531,11 +534,11 @@ jobs:
531534 azPSVersion : " latest"
532535 inlineScript : |
533536 (Get-AzContext).Environment.Name -eq 'AzureCloud'
534- (Get-AzResourceGroup -Name GitHubAction_CI_Group ).ResourceGroupName -eq 'GitHubAction_CI_Group'
537+ (Get-AzResourceGroup -Name $env:RG_POSITIVE ).ResourceGroupName -eq $env:RG_POSITIVE
535538
536539 - name : Check Last step failed
537540 if : steps.ps_8.outcome == 'success'
538- uses : actions/github-script@v7
541+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
539542 with :
540543 script : |
541544 core.setFailed('Last action should fail but not. Please check it.')
@@ -549,7 +552,7 @@ jobs:
549552 - name : Run Azure Cli
550553 run : |
551554 az account show --output none
552- az group show --name GitHubAction_CI_Group --output none
555+ az group show --name "${{ env.RG_POSITIVE }}" --output none
553556
554557 - name : Run Azure PowerShell
555558 id : ps_9
@@ -559,11 +562,11 @@ jobs:
559562 azPSVersion : " latest"
560563 inlineScript : |
561564 (Get-AzContext).Environment.Name -eq 'AzureCloud'
562- (Get-AzResourceGroup -Name GitHubAction_CI_Group ).ResourceGroupName -eq 'GitHubAction_CI_Group'
565+ (Get-AzResourceGroup -Name $env:RG_POSITIVE ).ResourceGroupName -eq $env:RG_POSITIVE
563566
564567 - name : Check Last step failed
565568 if : steps.ps_9.outcome == 'success'
566- uses : actions/github-script@v7
569+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
567570 with :
568571 script : |
569572 core.setFailed('Last action should fail but not. Please check it.')
@@ -582,7 +585,7 @@ jobs:
582585
583586 - name : Check Last step failed
584587 if : steps.login_10.outcome == 'success'
585- uses : actions/github-script@v7
588+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
586589 with :
587590 script : |
588591 core.setFailed('Last action should fail but not. Please check it.')
@@ -599,7 +602,7 @@ jobs:
599602
600603 - name : Check Last step failed
601604 if : steps.login_11.outcome == 'success'
602- uses : actions/github-script@v7
605+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
603606 with :
604607 script : |
605608 core.setFailed('Last action should fail but not. Please check it.')
@@ -619,7 +622,7 @@ jobs:
619622
620623 - name : Check Last step failed
621624 if : steps.login_12.outcome == 'success'
622- uses : actions/github-script@v7
625+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
623626 with :
624627 script : |
625628 core.setFailed('Last action should fail but not. Please check it.')
@@ -635,7 +638,7 @@ jobs:
635638
636639 - name : Check Last step failed
637640 if : steps.login_13.outcome == 'success'
638- uses : actions/github-script@v7
641+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
639642 with :
640643 script : |
641644 core.setFailed('Last action should fail but not. Please check it.')
@@ -651,7 +654,7 @@ jobs:
651654
652655 - name : Check Last step failed
653656 if : steps.login_14.outcome == 'success'
654- uses : actions/github-script@v7
657+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
655658 with :
656659 script : |
657660 core.setFailed('Last action should fail but not. Please check it.')
@@ -666,7 +669,7 @@ jobs:
666669
667670 - name : Check Last step failed
668671 if : steps.login_15.outcome == 'success'
669- uses : actions/github-script@v7
672+ uses : actions/github-script@f28e40c7f34bde8b3046d885e986cb6290c5673b # v7.1.0
670673 with :
671674 script : |
672675 core.setFailed('Last action should fail but not. Please check it.')
@@ -687,4 +690,4 @@ jobs:
687690 with :
688691 creds : ${{ secrets.PROVISION_CREDS }}
689692 - name : Delete resource group
690- run : az group delete --name "$RG_POSITIVE" --yes --output none || true
693+ run : az group delete --name "${{ env. RG_POSITIVE }} " --yes --output none || true
0 commit comments