简体   繁体   中英

Is it possible to change the network security group of a Azure VM via REST API?

我什至不知道如何通过门户更改 Azure VM 的网络安全组......我几乎没有从官方文档中找到任何有用的东西。

There are many ways to create and manage NSGs, such as using Portal, Powershell, CLI and REST API .

More about how to manage the network security group of an Azure VM via portal , refer to this document .

More about how to configure the network security group of an Azure VM via REST API , refer to this document .

Learn more about NSG, you can refer to this document .

  1. Click on the virtual machine and select "Networking" from the "Settings" menu.
  2. Click on the "Network Interface" associated to the VM.
  3. In the "Settings" menu of the Network Interface, click on "Network Security Group".
  4. Select the desired Network Security Group from the drop down menu and select "Save"

Note: VM should be shut down to do this.

Yeah that is possible

if you have multiple VMs with single NIC all those will be impacted with this change

Steps are pretty simple

  • Go to you VM
  • Navigate to Networking from Left pane
  • in the main panel you would see your associated NIC (Click on it)
  • In the NIC window from left pane select "Network Security Group"
  • From the drop down list select your Security group and then click on save button

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM