Skip to content

Commit

Permalink
Update __main__.py to subvert erroring out - You can no longer set an…
Browse files Browse the repository at this point in the history
… Azure SP Password - It is auto-generated

Title sums it up. Trying to pass a password to the azuread.ServicePrincipalPassword method did not allow me to successfully create an AKS cluster.
  • Loading branch information
patrickjburke245 authored Jan 27, 2024
1 parent 6e886de commit bd65ee7
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions azure-py-aks/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,9 @@
ad_app = azuread.Application("aks", display_name="aks")
ad_sp = azuread.ServicePrincipal("aksSp", application_id=ad_app.application_id)

# Generate random password
password = random.RandomPassword("password", length=20, special=True)

# Create the Service Principal Password
ad_sp_password = azuread.ServicePrincipalPassword("aksSpPassword",
service_principal_id=ad_sp.id,
value=password.result,
end_date="2099-01-01T00:00:00Z")

# Generate an SSH key
Expand Down

0 comments on commit bd65ee7

Please sign in to comment.