<- All Blueprints
Customizable templates for deploying cloud infrastructure

Azure SQL Server

This blueprint creates an Azure SQL Server with best practices such as requiring secure administrator credentials, defaulting to version 12.0, and encouraging the use of managed identities for enhanced security. It promotes the use of tags for better resource identification and management and organizes variables into logical groups to assist users—including those who may not be cloud infrastructure experts—in configuring essential and advanced settings easily.

Define and customize Blueprints to set what infrastructure configuration options are available to developers.

---
constants:
  __name: "{{ name }}_{{ __guid }}"
variables:
  name:
    desc: "Name of the SQL Server. Must be globally unique."
    required: true
    group: SQL Server Details
  resource_group_name:
    desc: "Name of the resource group."
    required: true
    group: SQL Server Details
    links_to: resource.azurerm_resource_group.name
  location:
    desc: "Azure region where the SQL Server will be created."
    required: true
    group: SQL Server Details
    default: "eastus"
  version:
    desc: "Version of the SQL Server."
    required: false
    group: SQL Server Details
    default: "12.0"
  administrator_login:
    desc: "Administrator username for the SQL Server."
    required: true
    group: Authentication
    default: "sqladminuser"
  administrator_login_password:
    desc: "Administrator password for the SQL Server. Must comply with Azure's password policies."
    required: true
    group: Authentication
  identity_type:
    desc: "Type of managed identity to assign to the SQL Server."
    required: false
    group: Identity
    default: "SystemAssigned"
    suggested: "SystemAssigned"
    advanced: true
  tags:
    group: Tags
    required: false
groups:
  SQL Server Details:
    order: 1
    desc: "Basic settings for the SQL Server."
  Authentication:
    order: 2
    desc: "Administrator credentials for the SQL Server."
  Identity:
    order: 3
    desc: "Managed identity settings for the SQL Server."
  Tags:
    order: 4
    desc: "Tags to assign to the SQL Server."
---

resource "azurerm_sql_server" "__name" {
  name                         = {{ name }}
  resource_group_name          = {{ resource_group_name }}
  location                     = {{ location }}
  version                      = {{ version }}
  administrator_login          = {{ administrator_login }}
  administrator_login_password = {{ administrator_login_password }}

  {{# identity_type }}
  identity {
    type = {{ identity_type }}
  }
  {{/ identity_type }}

  tags = {
    Name = {{ name }}
    {{# tags }}
      {{ tags.key | required: false }} = {{ tags.value | required: false }}
    {{/ tags }}
  }
}

// Enforces secure administrator credentials and encourages the use of managed identities.
// Tags are included for better resource management and identification.
//
A form is created automatically that accepts inputs that you defined in the Blueprint.
After filling out the Blueprint form, Terraform is generated and a PR is automatically submitted.
What am I looking at?

Talk to a Human

See Resourcely in action and learn how it can help you secure and manage your cloud infrastructure today!