Closed lotaezhao closed 4 years ago
@katbyte any chance this could be done on the SQL level as well and if possible broke out to its own resource?
Hi @lotaezhao ,thanks for opening this issue. Blob Auditing Policies are supported now on azurerm_sql_database
and azurerm_sql_server
. Hi @katbyte we may be able to close this issue.
Appears the documentation is missing for the extended_auditing_policy
block; so this wants fixing prior to closing this https://www.terraform.io/docs/providers/azurerm/r/sql_database.html
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!
Community Note
Description
There is currently no support to configure azure sql database audit-policy settings in Terraform. Please can this added as it's a pretty standard requirement within enterprises to need auditing switched on. Sql databases are one of of the most fundamental resources so we should have full feature support. This can be enabled both on individual databases and at the server level. I'm talking about the database level but might as well add support for sql server level as well.
New or Affected Resource(s)
azurerm_sql_database azurerm_sql_server
Potential Terraform Configuration
Basing this off of the 'az sql db audit-policy update' command, proposed configuration could be a new 'audit_policy' block with the following attributes.
References
This is the same configuration as provided by the Az Cli command 'az sql db audit-policy update' which is what I currently have to use in order to configure this setting: https://docs.microsoft.com/en-us/cli/azure/sql/db/audit-policy?view=azure-cli-latest
0000