Azure Devops Provider: Example Usage
Azure Devops Provider: Example Usage
Azure Devops Provider: Example Usage
com)
Use the navigation to the left to read about the available resources.
Example Usage
provider "azuredevops" {
version = ">= 0.0.1"
}
Argument Reference
The following arguments are supported in the provider block:
org_service_url - (Required) This is the Azure DevOps organization url. It can also be sourced from the
AZDO_ORG_SERVICE_URL environment variable.
personal_access_token - (Required) This is the Azure DevOps organization personal access token. The
account corresponding to the token will need "owner" privileges for this organization. It can also be sourced
from the AZDO_PERSONAL_ACCESS_TOKEN environment variable.
(https://www.hashicorp.com)
Example Usage
output "name" {
value = data.azuredevops_agent_pool.pool.name
}
output "pool_type" {
value = data.azuredevops_agent_pool.pool.pool_type
}
output "auto_provision" {
value = data.azuredevops_agent_pool.pool.auto_provision
}
Argument Reference
Attributes Reference
name - The name of the agent pool pool_type - Specifies whether the agent pool type is Automation or
Deployment. auto_provision - Specifies whether or not a queue should be automatically provisioned for each
project collection.
Relevant Links
Azure DevOps Service REST API 5.1 - Agent Pools - Get (https://docs.microsoft.com/en-
us/rest/api/azure/devops/distributedtask/pools/get?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
Example Usage
output "agent_pool_name" {
value = data.azuredevops_agent_pools.pools.agent_pools.*.name
}
output "auto_provision" {
value = data.azuredevops_agent_pools.pools.agent_pools.*.auto_provision
}
output "pool_type" {
value = data.azuredevops_agent_pools.pools.agent_pools.*.pool_type
}
Argument Reference
Attributes Reference
agent_pools - A list of existing agent pools in your Azure DevOps Organization with the following details
about every agent pool:
name - The name of the agent pool
auto_provision - Specifies whether or not a queue should be automatically provisioned for each
project collection.
Relevant Links
Azure DevOps Service REST API 5.1 - Agent Pools - Get (https://docs.microsoft.com/en-
us/rest/api/azure/devops/distributedtask/pools/get?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
Example Usage
output "org_url" {
value = data.azuredevops_client_config.c.organization_url
}
Argument Reference
Attributes Reference
Example Usage
Argument Reference
name - (Optional) Name of the Git repository to retrieve; requires project_id to be specified as well
DataSource without specifying any arguments will return all Git repositories of an organization.
Attributes Reference
repositories - A list of existing projects in your Azure DevOps Organization with details about every project
which includes:
Relevant Links
Example Usage
output "group_id" {
value = data.azuredevops_group.test.id
}
output "group_descriptor" {
value = data.azuredevops_group.test.descriptor
}
Argument Reference
Attributes Reference
descriptor - The Descriptor is the primary way to reference the graph subject. This field will uniquely identify
the same graph subject across both Accounts and Organizations.
Relevant Links
Azure DevOps Service REST API 5.1 - Groups - Get (https://docs.microsoft.com/en-
us/rest/api/azure/devops/graph/groups/get?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
Example Usage
output "id" {
value = data.azuredevops_project.p.id
}
output "project_name" {
value = data.azuredevops_project.p.project_name
}
output "visibility" {
value = data.azuredevops_project.p.visibility
}
output "version_control" {
value = data.azuredevops_project.p.version_control
}
output "work_item_template" {
value = data.azuredevops_project.p.work_item_template
}
output "process_template_id" {
value = data.azuredevops_project.p.process_template_id
}
Argument Reference
Attributes Reference
Relevant Links
Example Usage
output "project_id" {
value = data.azuredevops_projects.test.projects.*.project_id
}
output "project_name" {
value = data.azuredevops_projects.test.projects.*.name
}
output "project_url" {
value = data.azuredevops_projects.test.projects.*.project_url
}
output "state" {
value = data.azuredevops_projects.test.projects.*.state
}
Argument Reference
project_name - (Optional) Name of the Project, if not specified all projects will be returned.
state - (Optional) State of the Project, if not specified all projects will be returned. Valid values are all ,
deleting , new , wellFormed , createPending , unchanged , deleted .
Attributes Reference
projects - A list of existing projects in your Azure DevOps Organization with details about every project
which includes:
project_id - Project identifier.
Relevant Links
Example Usage
Argument Reference
principal_name - (Optional) The PrincipalName of this graph member from the source provider.
subject_types - (Optional) A list of user subject subtypes to reduce the retrieved results, e.g. msa , aad , svc
(service identity), imp (imported identity), etc. The supported subject types are listed below.
origin - (Optional) The type of source provider for the origin_id parameter (ex:AD, AAD, MSA) The
supported origins are listed below.
DataSource without specifying any arguments will return all users inside an organization.
List of possible subject types
Attributes Reference
users - A list of existing users in your Azure DevOps Organization with details about every single user which
includes:
descriptor - The descriptor is the primary way to reference the graph subject while the system is
running. This field will uniquely identify the same graph subject across both Accounts and Organizations.
principal_name - This is the PrincipalName of this graph member from the source provider. The source
provider may change this field over time and it is not guaranteed to be immutable for the life of the
graph member by VSTS.
origin - The type of source provider for the origin identifier (ex:AD, AAD, MSA)
origin_id - The unique identifier from the system of origin. Typically a sid, object id or Guid. Linking
and unlinking operations can cause this value to change for a user because the user is not backed by a
different provider and has a different unique id in the new provider.
display_name - This is the non-unique display name of the graph subject. To change this field, you
must alter its value in the source provider.
mail_address - The email address of record for a given graph member. This may be different than the
principal name.
Relevant Links
Azure DevOps Service REST API 5.1 - Graph Users API (https://docs.microsoft.com/en-
us/rest/api/azure/devops/graph/users?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
Configuration
Configuration file requires azuredevops provider section. Then use any resources and data sources you want.
provider "azuredevops" {
version = ">= 0.0.1"
}
azuredevops_agent_pool
Manages an agent pool within Azure DevOps.
Example Usage
Argument Reference
auto_provision - (Optional) Specifies whether or not a queue should be automatically provisioned for each
project collection. Defaults to false .
pool_type - (Optional) Specifies whether the agent pool type is Automation or Deployment. Defaults to
automation .
Attributes Reference
Relevant Links
Import
Azure DevOps Agent Pools can be imported using the agent pool Id, e.g.
terraform import azuredevops_agent_pool.pool 42
(https://www.hashicorp.com)
azuredevops_agent_queue
Manages an agent queue within Azure DevOps. In the UI, this is equivelant to adding an Organization defined pool
to a project.
The created queue is not authorized for use by all pipeliens in the project. However, the
azuredevops_resource_authorization resource can be used to grant authorization.
Example Usage
Argument Reference
Attributes Reference
Import
Azure DevOps Agent Pools can be imported using the project ID and agent queue ID, e.g.
azuredevops_git_repository
Manages a git repository within Azure DevOps.
Example Usage
Argument Reference
init_type - (Required) The type of repository to create. Valid values: Uninitialized , Clean , or Import .
Defaults to Uninitialized .
source_type - (Optional) Type type of the source repository. Used if the init_type is Import .
source_url - (Optional) The URL of the source repository. Used if the init_type is Import .
Attributes Reference
In addition to all arguments above, except initialization , the following attributes are exported:
Relevant Links
azuredevops_branch_policy_build_validation
Manages a build validation branch policy within Azure DevOps.
Example Usage
resource "azuredevops_project" "p" {
project_name = "Sample Project"
}
repository {
repo_type = "TfsGit"
repo_id = azuredevops_git_repository.r.id
yml_path = "azure-pipelines.yml"
}
}
enabled = true
blocking = true
settings {
display_name = "Don't break the build!"
build_definition_id = azuredevops_build_definition.b.id
valid_duration = 720
scope {
repository_id = azuredevops_git_repository.r.id
repository_ref = azuredevops_git_repository.r.default_branch
match_type = "Exact"
}
scope {
repository_id = azuredevops_git_repository.r.id
repository_ref = "refs/heads/releases"
match_type = "Prefix"
}
}
}
Argument Reference
project_id - (Required) The ID of the project in which the policy will be created.
enabled - (Optional) A flag indicating if the policy should be enabled. Defaults to true .
blocking - (Optional) A flag indicating if the policy should be blocking. Defaults to true .
settings - (Required) Configuration for the policy. This block must be defined exactly once.
manual_queue_only - (Optional) If set to true, the build will need to be manually queued. Defaults to false
queue_on_source_update_only - (Optional) True if the build should queue on source updates only. Defaults to
true .
valid_duration - (Optional) The number of minutes for which the build is valid. If 0 , the build will not expire.
Defaults to 720 (12 hours).
scope (Required) Controls which repositories and branches the policy will be enabled for. This block must be
defined at least once.
A settings scope block supports the following: * repository_id - (Optional) The repository ID. Needed only if
the scope of the policy will be limited to a single repository. * repository_ref - (Optional) The ref pattern to use for
the match. If match_type is Exact , this should be a qualified ref such as refs/heads/master . If match_type is
Prefix , this should be a ref path such as refs/heads/releases . * match_type (Optional) The match type to use
when applying the policy. Supported values are Exact (default) or Prefix .
Attributes Reference
Relevant Links
Import
Azure DevOps Branch Policies can be imported using the project ID and policy configuration ID:
azuredevops_branch_policy_min_reviewers
Manages a minimum reviewer branch policy within Azure DevOps.
Example Usage
enabled = true
blocking = true
settings {
reviewer_count = 2
submitter_can_vote = false
scope {
repository_id = azuredevops_git_repository.r.id
repository_ref = azuredevops_git_repository.r.default_branch
match_type = "Exact"
}
scope {
repository_id = azuredevops_git_repository.r.id
repository_ref = "refs/heads/releases"
match_type = "Prefix"
}
}
}
Argument Reference
project_id - (Required) The ID of the project in which the policy will be created.
enabled - (Optional) A flag indicating if the policy should be enabled. Defaults to true .
blocking - (Optional) A flag indicating if the policy should be blocking. Defaults to true .
settings - (Required) Configuration for the policy. This block must be defined exactly once.
submitter_can_vote - (Optional) Controls whether or not the submitter's vote counts. Defaults to false .
scope (Required) Controls which repositories and branches the policy will be enabled for. This block must be
defined at least once.
A settings scope block supports the following: * repository_id - (Optional) The repository ID. Needed only if
the scope of the policy will be limited to a single repository. * repository_ref - (Optional) The ref pattern to use for
the match. If match_type is Exact , this should be a qualified ref such as refs/heads/master . If match_type is
Prefix , this should be a ref path such as refs/heads/releases . * match_type (Optional) The match type to use
when applying the policy. Supported values are Exact (default) or Prefix .
Attributes Reference
Relevant Links
Import
Azure DevOps Branch Policies can be imported using the project ID and policy configuration ID:
azuredevops_build_definition
Manages a Build Definition within Azure DevOps.
Example Usage
variable {
name = "FOO"
value = "BAR"
}
}
ci_trigger {
use_yaml = true
}
repository {
repo_type = "TfsGit"
repo_id = azuredevops_git_repository.repository.id
branch_name = azuredevops_git_repository.repository.default_branch
yml_path = "azure-pipelines.yml"
}
variable_groups = [
azuredevops_variable_group.vars.id
]
variable {
name = "PipelineVariable"
value = "Go Microsoft!"
}
variable {
name = "PipelineSecret"
secret_value = "ZGV2cw"
is_secret = true
}
}
Argument Reference
agent_pool_name - (Optional) The agent pool that should execute the build. Defaults to Hosted Ubuntu 1604 .
variable_groups - (Optional) A list of variable group IDs (integers) to link to the build definition.
secret_value - (Optional) The secret value of the variable. Used when is_secret set to true .
branch_name - (Optional) The branch name for which builds are triggered. Defaults to master .
repo_id - (Required) The id of the repository. For TfsGit repos, this is simply the ID of the repository. For
Github repos, this will take the form of <GitHub Org>/<Repo Name> . For Bitbucket repos, this will take the
form of <Workspace ID>/<Repo Name> .
repo_type - (Optional) The repository type. Valid values: GitHub or TfsGit or Bitbucket . Defaults to
Github .
service_connection_id - (Optional) The service connection ID. Used if the repo_type is GitHub .
yml_path - (Required) The path of the Yaml file describing the build definition.
use_yaml - (Optional) Use the azure-pipeline file for the build configuration. Defaults to false .
override - (Optional) Override the azure-pipeline file and use a this configuration for all builds.
batch - (Optional) If you set batch to true, when a pipeline is running, the system waits until the run is
completed, then starts another run with all changes that have not yet been built. Defaults to true .
branch_filter - (Optional) The branches to include and exclude from the trigger.
path_filter - (Optional) Specify file paths to include or exclude. Note that the wildcard syntax is different
between branches/tags and file paths.
polling_job_id - (Computed) This is the ID of the polling job that polls the external repository. Once the
build definition is saved/updated, this value is set.
use_yaml - (Optional) Use the azure-pipeline file for the build configuration. Defaults to false .
initial_branch - (Optional) When use_yaml is true set this to the name of the branch that the azure-
pipelines.yml exists on. Defaults to Managed by Terraform .
override - (Optional) Override the azure-pipeline file and use a this configuration for all builds.
branch_filter - (Optional) The branches to include and exclude from the trigger.
path_filter - (Optional) Specify file paths to include or exclude. Note that the wildcard syntax is different
between branches/tags and file paths.
branch_filter block supports the following:
Attributes Reference
Relevant Links
Import
Azure DevOps Build Definitions can be imported using the project name/definitions Id or by the project
Guid/definitions Id, e.g.
azuredevops_group
Manages a group within Azure DevOps.
Example Usage
members = [
data.azuredevops_group.tf-project-readers.descriptor,
data.azuredevops_group.tf-project-contributors.descriptor
]
}
Argument Reference
scope - (Optional) The scope of the group. A descriptor referencing the scope (collection, project) in which
the group should be created. If omitted, will be created in the scope of the enclosing account or organization.x
origin_id - (Optional) The OriginID as a reference to a group from an external AD or AAD backed provider.
The scope , mail and display_name arguments cannot be used simultaneously with origin_id .
mail - (Optional) The mail address as a reference to an existing group from an external AD or AAD backed
provider. The scope , origin_id and display_name arguments cannot be used simultaneously with mail .
display_name - (Optional) The name of a new Azure DevOps group that is not backed by an external
provider. The origin_id and mail arguments cannot be used simultaneously with display_name .
description - (Optional) The Description of the Project.
members - (Optional) > NOTE: It's possible to define group members both within the azuredevops_group
resource via the members block and by using the azuredevops_group_membership resource. However it's not
possible to use both methods to manage group members, since there'll be conflicts.
Attributes Reference
url - This url is the full route to the source resource of this graph subject.
origin - The type of source provider for the origin identifier (ex:AD, AAD, MSA)
subject_kind - This field identifies the type of the graph subject (ex: Group, Scope, User).
domain - This represents the name of the container of origin for a graph member.
principal_name - This is the PrincipalName of this graph member from the source provider.
Relevant Links
Import
Azure DevOps Projects can be imported using the group identity descriptor, e.g.
azuredevops_group_membership
Manages group membership within Azure DevOps.
Example Usage
Argument Reference
members - (Required) A list of user or group descriptors that will become members of the group. > NOTE: It's
possible to define group members both within the azuredevops_group_membership resource via the
members block and by using the azuredevops_group resource. However it's not possible to use both methods
to manage group members, since there'll be conflicts.
mode - (Optional) The mode how the resource manages group members.
mode == add : the resource will ensure that all specified members will be part of the referenced group
mode == overwrite : the resource will replace all existing members with the members specified within
the members block > NOTE: To clear all members from a group, specify an empty list of descriptors in
the members attribute and set the mode member to overwrite .
Attributes Reference
id - A random ID for this resource. There is no "natural" ID, so a random one is assigned.
Relevant Links
Import
Not supported.
azuredevops_project_features
Manages features for Azure DevOps projects
Example Usage
provider "azuredevops" {
version = ">= 0.0.1"
}
Argument Reference
projectd_id - (Required) The id of the project for which the project features will be managed.
features - (Required) Defines the status ( enabled , disabled ) of the project features.
Valid features boards , repositories , pipelines , testplans , artifacts
NOTE:
It's possible to define project features both within the azuredevops_project_features resource
(/docs/providers/ado/r/project_features.html) and via the features block by using the
azuredevops_project resource (/docs/providers/ado/r/project.html). However it's not possible to use both
methods to manage group members, since there'll be conflicts.
Attributes Reference
Import
Azure DevOps feature settings can be imported using the project id, e.g.
azuredevops_project
Manages a project within Azure DevOps.
Example Usage
features = {
"testplans" = "disabled"
"artifacts" = "disabled"
}
}
Argument Reference
visibility - (Optional) Specifies the visibility of the Project. Valid values: private or public . Defaults to
private .
version_control - (Optional) Specifies the version control system. Valid values: Git or Tfvc . Defaults to
Git .
features - (Optional) Defines the status ( enabled , disabled ) of the project features.
Valid features boards , repositories , pipelines , testplans , artifacts
NOTE:
It's possible to define project features both within the azuredevops_project_features resource
(/docs/providers/ado/r/project_features.html) and via the features block by using the
azuredevops_project resource (/docs/providers/ado/r/project.html). However it's not possible to use both
methods to manage group members, since there'll be conflicts.
Attributes Reference
Relevant Links
Import
Azure DevOps Projects can be imported using the project name or by the project Guid, e.g.
or
azuredevops_resource_authorization
Manages authorization of resources, e.g. for access in build pipelines.
Example Usage
resource "azuredevops_project" "p" {
project_name = "Test Project"
}
Argument Reference
The following arguments are supported:
Attributes Reference
The following attributes are exported:
n/a
Relevant Links
Azure DevOps Service REST API 5.1 - Authorize Definition Resource (https://docs.microsoft.com/en-
us/rest/api/azure/devops/build/resources/authorize%20definition%20resources?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
azuredevops_serviceendpoint_azurerm
Manages Manual or Automatic AzureRM service endpoint within Azure DevOps.
Before to create a service end point in Azure DevOps, you need to create a Service Principal in your Azure
subscription.
For detailed steps to create a service principal with Azure cli see the documentation
(https://docs.microsoft.com/en-us/cli/azure/create-an-azure-service-principal-azure-cli?view=azure-cli-
latest)
Example Usage
Argument Reference
resource_group - (Optional) The resource group used for scope of automatic service endpoint.
Attributes Reference
Azure DevOps Service REST API 5.1 - Service End points (https://docs.microsoft.com/en-
us/rest/api/azure/devops/serviceendpoint/endpoints?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
azuredevops_serviceendpoint_bitbucket
Manages a Bitbucket service endpoint within Azure DevOps.
Example Usage
Argument Reference
Attributes Reference
Import
Azure DevOps Service Endpoint Bitbucket can be imported using the projectID/serviceEndpointID, e.g.
azuredevops_serviceendpoint_dockerhub
Manages a Docker Hub service endpoint within Azure DevOps.
Example Usage
docker_username = "sample"
docker_email = "[email protected]"
docker_password = "12345"
Argument Reference
Relevant Links
azuredevops_serviceendpoint_dockerhub
Manages a Docker Registry service endpoint within Azure DevOps.
Example Usage
docker_username = "sample"
docker_email = "[email protected]"
docker_password = "12345"
registry_type = "DockerHub"
}
Argument Reference
service_endpoint_name - (Required) The name you will use to refer to this service connection in task inputs.
description - (Optional) The name you will use to refer to this service connection in task inputs.
docker_registry - (Optional) The URL of the Docker registry. (Default: " https://index.docker.io/v1/"
(https://index.docker.io/v1/%22))
docker_username - (Optional) The identifier of the Docker account user.
docker_password - (Optional) The password for the account user identified above.
Attributes Reference
Relevant Links
azuredevops_serviceendpoint_github
Manages a GitHub service endpoint within Azure DevOps.
Example Usage
auth_personal {
personal_access_token = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
}
}
auth_oauth {
oauth_configuration_id = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}
}
description = ""
}
Argument Reference
auth_oauth - (Optional) An auth_oauth block as documented below. Allows connecting using an Oauth
token.
NOTE: Github Apps can not be created or updated via terraform. You must install and configure the app on Github
and then import it. You must also set the description to "" explicitly."
oauth_configuration_id - (Required) NOTE: Github OAuth flow can not be performed via terraform. You
must create this on Azure DevOps and then import it. The OAuth Configuration ID.
Attributes Reference
Relevant Links
Import
Azure DevOps Service Endpoint GitHub can be imported using the serviceendpoint id, e.g.
azuredevops_serviceendpoint_kubernetes
Manages a Kubernetes service endpoint within Azure DevOps.
Example Usage
data "azuredevops_project" "p" {
project_name = "contoso"
}
azure_subscription {
subscription_id = "001ac454-bb17-475a-8648-82c4234545be"
subscription_name = "Microsoft Azure DEMO"
tenant_id = "8c46c3eb-ca1f-4a0b-8dfa-7c3baaf69d45"
resourcegroup_id = "sample-rg"
namespace = "default"
cluster_name = "sample-aks"
}
}
kubeconfig {
kube_config = <<EOT
apiVersion: v1
clusters:
- cluster:
certificate-authority: fake-ca-file
server: https://1.2.3.4
name: development
contexts:
- context:
cluster: development
namespace: frontend
user: developer
name: dev-frontend
current-context: dev-frontend
kind: Config
preferences: {}
users:
- name: developer
user:
client-certificate: fake-cert-file
client-key: fake-key-file
EOT
accept_untrusted_certs = true
accept_untrusted_certs = true
cluster_context = "dev-frontend"
}
}
service_account {
token = "bXktYXBw[...]K8bPxc2uQ=="
ca_cert = "Mzk1MjgkdmRnN0pi[...]mHHRUH14gw4Q=="
}
}
Argument Reference
The following arguments are supported:
Attributes Reference
The following attributes are exported:
id - The ID of the service endpoint.
project_id - The project ID or project name.
service_endpoint_name - The Service Endpoint name.
Relevant Links
Azure DevOps Service REST API 5.1 - Endpoints (https://docs.microsoft.com/en-
us/rest/api/azure/devops/serviceendpoint/endpoints?view=azure-devops-rest-5.1)
(https://www.hashicorp.com)
azuredevops_user_entitlement
Manages a user entitlement within Azure DevOps.
Example Usage
Argument Reference
principal_name - (Optional) The principal name is the PrincipalName of a graph member from the source
provider. Usually, e-mail address.
origin_id - (Optional) The unique identifier from the system of origin. Typically a sid, object id or Guid. e.g.
Used for member of other tenant on Azure Active Directory.
origin - (Optional) The type of source provider for the origin identifier.
licensing_source - (Optional) The source of the licensing (e.g. Account. MSDN etc.) Valid values: account
(Default), auto , msdn , none , profile , trail
NOTE: A user can only be referenced by it's principal_name or by the combination of origin_id and
origin .
Attributes Reference
descriptor - The descriptor is the primary way to reference the graph subject while the system is running.
This field will uniquely identify the user graph subject.
Relevant Links
Azure DevOps Service REST API 5.1 - User Entitlements - Add (https://docs.microsoft.com/en-
us/rest/api/azure/devops/memberentitlementmanagement/user%20entitlements/add?view=azure-
devops-rest-5.1)
Import
The resources allows the import via the UUID of a user entitlement or by using the principal name of a user owning
an entitlement.
azuredevops_variable_group
Manages variable groups within Azure DevOps.
Example Usage
variable {
name = "key"
value = "value"
}
variable {
name = "Account Password"
value = "p@ssword123"
is_secret = true
}
}
Argument Reference
allow_access - (Required) Boolean that indicate if this variable group is shared by all pipelines of this project.
name - (Required) The key value used for the variable. Must be unique within the Variable Group.
value - (Optional) The value of the variable. If omitted, it will default to empty string.
secret_value - (Optional) The secret value of the variable. If omitted, it will default to empty string. Used
when is_secret set to true .
is_secret - (Optional) A boolean flag describing if the variable value is sensitive. Defaults to false .
Attributes Reference
Relevant Links
Import
Azure DevOps Variable groups can be imported using the project name/variable group Id or by the project
Guid/variable group Id, e.g.
Note that for secret variables, the import command retrieve blank value in the tfstate.