官术网_书友最值得收藏!

  • Learning DevOps
  • Mikael Krief
  • 187字
  • 2021-06-24 12:32:05

Terraform configuration for local development and testing

When you work locally and want to test the Terraform code quickly, in a sandbox environment, for example, it may be more convenient and faster to use your own Azure account instead of using an SP.

To do this, it is possible to connect to Azure beforehand with the az login command, and then enter your identification information in the window that opens. 

The following is a screenshot of the Azure login window:

If several subscriptions are accessed, the desired one can be selected with the following command:

az account set --subscription="<Subscription ID>"

Then, we configure the Terraform provider as before with the provider, "azurerm" { }.

Of course, this authentication method is not to be done in the case of execution on a remote server.

For more information on the provider configuration, refer to the documentation:  https://www.terraform.io/docs/providers/azurerm/index.html.

The Terraform configuration for Azure is, therefore, defined by the configuration of the provider that uses the information from an Azure SP.

Once this configuration is complete, we can start writing Terraform code to manage and provision Azure resources.

主站蜘蛛池模板: 明光市| 五指山市| 丰顺县| 吉木萨尔县| 淮南市| 通海县| 昭苏县| 安平县| 新宁县| 布拖县| 道真| 嵊泗县| 孟津县| 拉萨市| 孝义市| 安溪县| 郑州市| 托里县| 志丹县| 夏河县| 桃园市| 顺义区| 镇原县| 彭阳县| 佛坪县| 新兴县| 平远县| 怀宁县| 淳安县| 包头市| 富源县| 兴安县| 信宜市| 兴安县| 德清县| 安西县| 兴国县| 徐州市| 叶城县| 定陶县| 彩票|