You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would expect a new credential to be created for the SP, and the old one to be left in place so that applications can continue to run correctly until they pick up the new credential.
The nomenclature "rotation" suggests that the old credential will be left intact.
Actual Behavior
The old credential was deleted and a new one was created.
Steps to Reproduce
terraform apply
List the credentials for this SP (using the SP id in the output):
az ad sp credential list --id 0092bcc0-xxxx-xxxx-xxxx-xxxxxxxxxxxx
[
{
"customKeyIdentifier": null,
"displayName": null,
"endDateTime": "2026-12-19T00:42:06.2182111Z",
"hint": "1Zx",
"keyId": "670007de-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"secretText": null,
"startDateTime": "2024-12-19T00:42:06.2182111Z"
}
]
Change azuread_service_principal_password.example.rotate_when_changed.rotation to 2.
terraform apply
List the credentials again
az ad sp credential list --id 0092bcc0-xxxx-xxxx-xxxx-xxxxxxxxxxxx
[
{
"customKeyIdentifier": null,
"displayName": null,
"endDateTime": "2026-12-19T00:51:12.4838138Z",
"hint": "vQ7",
"keyId": "6f3db624-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"secretText": null,
"startDateTime": "2024-12-19T00:51:12.4838138Z"
}
]
Note that the old SP credential is destroyed and a new one is created.
Important Factoids
References
The text was updated successfully, but these errors were encountered:
Community Note
Terraform (and AzureAD Provider) Version
terraform -v
Affected Resource(s)
azuread_service_principal_password
Terraform Configuration Files
Debug Output
https://gist.github.com/rquackenbush/c51cb7658d4724709b980a590c9f7353
Panic Output
Expected Behavior
I would expect a new credential to be created for the SP, and the old one to be left in place so that applications can continue to run correctly until they pick up the new credential.
The nomenclature "rotation" suggests that the old credential will be left intact.
Actual Behavior
The old credential was deleted and a new one was created.
Steps to Reproduce
terraform apply
List the credentials for this SP (using the SP id in the output):
Change
azuread_service_principal_password.example.rotate_when_changed.rotation
to 2.terraform apply
List the credentials again
Note that the old SP credential is destroyed and a new one is created.
Important Factoids
References
The text was updated successfully, but these errors were encountered: