Skip to content

Commit 7a8b4ff

Browse files
deploy aks
1 parent 10a8957 commit 7a8b4ff

1 file changed

Lines changed: 12 additions & 9 deletions

File tree

.github/workflows/deploy-aks-construction.yml

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,29 +4,32 @@ on:
44
workflow_dispatch:
55

66
permissions:
7-
id-token: write
8-
contents: read
7+
id-token: write #This is required for requesting the JWT
8+
contents: write # This is required to create/push the new git tag
99

1010
jobs:
1111
create_resource_group_job:
1212
runs-on: ubuntu-latest
1313
steps:
14-
- name: Checkout
15-
uses: actions/checkout@v2
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
- name: Login to Azure
18+
uses: azure/login@v2
19+
with:
20+
client-id: ${{ secrets.AZURE_CLIENT_ID }}
21+
tenant-id: ${{ secrets.AZURE_TENANT_ID }}
22+
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
1623
- name: Create Resource Group
1724
id: create_rg
1825
run: |
19-
az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }}
20-
az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }}
2126
az group create --name ${{ env.RESOURCE_GROUP_NAME }} --location ${{ env.LOCATION }}
2227
env:
23-
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
24-
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
25-
AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
2628
RESOURCE_GROUP_NAME: rg-k8s-pygoat-dev-001
2729
LOCATION: canadacentral
2830
reusable_workflow_job:
2931
uses: Azure/AKS-Construction/.github/workflows/AKSC_Deploy.yml@0.10.5
32+
needs: create_resource_group_job
3033
with:
3134
templateVersion: 0.10.5
3235
rg: rg-k8s-pygoat-dev-001

0 commit comments

Comments
 (0)