Example of OpenAI generated article

This commit is contained in:
Tom Archer 2023-02-15 16:02:33 -08:00
parent c2a3a784d8
commit e3525093f0
6 changed files with 82 additions and 0 deletions

View File

@ -0,0 +1 @@
Article not yet tested by automated testing pipeline.

View File

@ -0,0 +1,22 @@
resource "random_pet" "rg_name" {
prefix = var.resource_group_name_prefix
}
resource "azurerm_resource_group" "rg" {
name = random_pet.rg_name.id
location = var.resource_group_location
}
resource "azurerm_analysis_services_server" "server" {
name = var.server_name
resource_group_name = azurerm_resource_group.rg.name
location = azurerm_resource_group.rg.location
sku = var.sku
backup_blob_container_uri = var.backup_blob_container_uri
ipv4_firewall_rule {
name = "AllowFromAll"
range_start = "0.0.0.0"
range_end = "255.255.255.255"
}
}

View File

@ -0,0 +1 @@

View File

@ -0,0 +1,16 @@
terraform {
required_version = ">=0.12"
required_providers {
azurerm = {
source = "hashicorp/azurerm"
version = "~>2.0"
}
random = {
source = "hashicorp/random"
version = "~>3.0"
}
}
}
provider "azurerm" {
features {}
}

View File

@ -0,0 +1,19 @@
# Azure Analysis Services server
This template deploys an Azure Analysis Services server.
## Terraform resource types
- [random_pet](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/pet)
- [azurerm_resource_group](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/resource_group)
- [azurerm_analysis_services_server](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/analysis_services_server)
## Variables
| Name | Description | Default |
|-|-|-|
| `resource_group_name_prefix` | Prefix of the resource group name that's combined with a random ID so name is unique in your Azure subscription. | rg |
| `resource_group_location` | Location of the resource group. | eastus |
| `server_name` | Name of the Azure Analysis Services server. | |
| `sku` | SKU name of the Azure Analysis Services server to create. | S0 |
| `backup_blob_container_uri` | SAS URI to a private Azure Blob Storage container with read, write and list permissions. | null |

View File

@ -0,0 +1,23 @@
variable "resource_group_location" {
default = "eastus"
description = "Location for all resources."
}
variable "resource_group_name_prefix" {
default = "rg"
description = "Prefix of the resource group name that's combined with a random ID so name is unique in your Azure subscription."
}
variable "server_name" {
description = "The name of the Azure Analysis Services server to create. Server name must begin with a letter, be lowercase alphanumeric, and between 3 and 63 characters in length. Server name must be unique per region."
}
variable "sku" {
description = "The sku name of the Azure Analysis Services server to create. Choose from: B1, B2, D1, S0, S1, S2, S3, S4, S8, S9. Some skus are region specific. See https://docs.microsoft.com/en-us/azure/analysis-services/analysis-services-overview#availability-by-region"
default = "S0"
}
variable "backup_blob_container_uri" {
description = "The SAS URI to a private Azure Blob Storage container with read, write and list permissions. Required only if you intend to use the backup/restore functionality. See https://docs.microsoft.com/en-us/azure/analysis-services/analysis-services-backup"
default = null
}