Terraform script to enable native client support for Azure Bastion host

Atanu Gupta 186 Reputation points
2022-09-14T10:24:30.667+00:00

Hello,

Just wanted to know if there is any terraform script to enable native client support for Azure Bastion host. From the portal I can do it by the following way but not sure how to enable it via terraform script

241041-bastionnew.png

Checked this doc below also but nothing as such mentioned regarding this

https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/bastion_host

Thanks in anticipation.

Azure Bastion
Azure Bastion
An Azure service that provides private and fully managed Remote Desktop Protocol (RDP) and Secure Shell (SSH) access to virtual machines.
292 questions
0 comments No comments
{count} votes

Accepted answer
  1. GitaraniSharma-MSFT 50,021 Reputation points Microsoft Employee Moderator
    2022-09-14T10:36:39.41+00:00

    Hello @Atanu Gupta ,

    Welcome to Microsoft Q&A Platform. Thank you for reaching out & hope you are doing well.

    I understand that you would like to know if there is any terraform script to enable native client support for Azure Bastion host.

    If we check the Azure CLI commands for Bastion host, we can see that to enable native client support, we need to add the parameter "--enable-tunneling".
    Refer : https://learn.microsoft.com/en-us/cli/azure/network/bastion?view=azure-cli-latest#az-network-bastion-update

    And if we check the Terraform registry for Azure Bastion host, we can see this parameter is available.
    https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/bastion_host

    tunneling_enabled - (Optional) Is Tunneling feature enabled for the Bastion Host. Defaults to false.
    Note: tunneling_enabled is only supported when sku is Standard.

    So, to enable native client support for Azure Bastion host via Terraform, you need to add this parameter "tunneling_enabled" and set it to "true".
    I could not find any readily available script for this.

    Kindly let us know if the above helped or you need further assistance on this issue.

    ----------------------------------------------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.