Check! Create an environment for Azure Bastion with Azure CLI

Kazumi IWANAGA (OHIRA)
1 min readNov 19, 2019

Azure Bastion is useful to connect to virtual machines instantly and keep safe your virtual network that insides machines.

Currently, Azure CLI doesn’t support creation of Azure Bastion yet. But the feature request has raised on issues like below. So I expect to become be able to use that.

Although, we can prepare the environment almost by using Azure CLI now. See the sample code below.

Then, you can deploy Azure Bastion through the Azure portal or Azure PowerShell. See the pages below.

Or you can create the Bastion from VM’s blade on the Azure portal. Click Connect and select BASTION tab, then you get the blade to create new Azure Bastion. Set your public address that created at above, and click Create button.

After that, you can access your VM through the Bastion safely.

--

--

Kazumi IWANAGA (OHIRA)

Hello! :) I’m a developer, Microsoft MVP(Azure). My interests: Azure, Serverless, IaC, Container, IoT, and other many exciting things!