Enabling PostgreSQL flexible server logs and configuring a retention period using Terraform

Screenshot of a Terraform configuration for an Azure PostgreSQL Flexible Server, highlighting the settings for server logs. The image shows the Terraform script with logging configurations enabled and the retention_period parameter set. The configuration specifies that server logging is active and defines the duration for which logs are retained.

In this blog post, we will look at enabling PostgreSQL flexible server logs and setting a retention period using Terraform. (Somewhat a new feature (was in Preview), the ability to enable server logs.) Deploying a sample server below, we can see within “Server Logs” that it currently isn’t enabled by default. Reviewing the linked learn.microsoft.com … Read more