Skip to content

Azure

Azure Subscription

resource "azure_subscription" "name" {
...
}
AttributeDescription

Regions regions

type: []string

The regions infrastructure can be provisioned into.

regions = [“westeurope”]

Services services

type: []string

The services to allow access to.

services = [“Microsoft.Compute”]

Tags tags

type: map[string]string

Tags to add to the subscription.

tags = {
key = “value”
}

Users user

type: []block User

Users that will be created within the subscription.

user “admin” {
roles = [
"Owner"

] } | |

ServicePrincipals service_principal

type: []block ServicePrincipal

|

Service Principals that will be created within the subscription.

service_principal “admin” {
roles = [
“Owner”
]
}
| |

TenantID tenant_id

type: string

| Output parameters | |

SubscriptionID subscription_id

type: string

| |

These attributes are computed when the config is parsed and applied, and are
therefore only known at parsetime or runtime.

AttributeDescription

Meta ID meta.id

string

The full ID of the resource e.g. resource.type.name.
This is computed from the full resource path:

// given the following resource
resource “container” “ubuntu” {
}

// the resulting id will be resource.container.ubuntu | |

Meta Type meta.type

string

|

The type of the resource.
This taken from the type label of the resource definition.

// given the following resource
resource “container” “ubuntu” {
…
}

// the resulting type will be container

| |

Meta Name meta.name

string

|

The name of the resource.
This taken from the name label of the resource definition.

// given the following resource
resource “container” “ubuntu” {
…
}

// the resulting name will be ubuntu

|


\


Azure User

resource "azure_subscription" "name" {
user "name" {
...
}
}
AttributeDescription

Name name required


type: string

The username of the user.

user “username” {
}

Roles roles

type: []string

The roles that will be assigned to the user.

roles = [“Owner”]

UserID user_id

type: string

Output parameters

Username username

type: string

Password password

type: string

These attributes are computed when the config is parsed and applied, and are
therefore only known at parsetime or runtime.


\


Azure Service Principal

resource "azure_subscription" "name" {
service_principal "name" {
...
}
}
AttributeDescription

Name name required


type: string

The name of the service principal.

service_principal “name” {
}

Roles roles

type: []string

The roles that will be assigned to the service principal.

roles = [“Owner”]

ServicePrincipalID service_principal_id

type: string

Output parameters

AppID app_id

type: string

Password password

type: string

These attributes are computed when the config is parsed and applied, and are
therefore only known at parsetime or runtime.