DEV Community

Cover image for Azure Management Tasks #Part 2: How to configure the virtual network (VNET)

Azure Management Tasks #Part 2: How to configure the virtual network (VNET)

Table of Contents


Introduction

In the previous part of this series, we prepared our environment for Azure management tasks by creating a resource group, a virtual network, a virtual machine, and a storage account. If you have not done that, please refer back to #Part 1 of the series before moving on.

In this article we would be creating a new subnet for SFTP (secure file transfer protocol) traffic in the existing virtual network. We would also create a network security group to manage inbound and outbound access.


Prerequisite

To successfully complete the tasks in this project, you need to

  • Login to Microsoft Azure portal.
  • Complete the tasks in the previous article.
  • Basic understanding of virtual networks and subnets.

Step 1: Create a new subnet on an existing virtual network (vNet).

  • From the Azure portal home page, in the search box, enter virtual networks.
  • Select virtual networks under services.

Search for and select virtual network.

  • Select the management-tasks-vnetvirtual network.

Select your Vnet.

  • From the management-tasks-vnetblade, under settings, select Subnets.
  • To add a subnet, select + Subnet.
  • For Subnet purpose leave it as Default.
  • For Name enter: ftpSubnet.
  • Leave the rest of the settings alone and select Add.
  • Select Home to return to the Azure portal home page.

Create a new subnet.


Step 2: Create a network security group.

  • From the Azure portal home page, in the search box, enter virtual networks.
  • Select virtual networks under services.
  • Select Network security groups.
  • Select + Create.

creating NSG.

  • Verify the subscription is correct.
  • Select the management-tasks-rg resource group.
  • Enter ftpNSG for the network security group name.
  • Select Review + create.

Review NSG configurations.

  • Once the validation is complete, select Create.

Confirm creation.

  • Wait for the screen to refresh and display Your deployment is complete.
  • Select Go to resource.

Go to the resource.


Step 3: Create an inbound security rule.

  • Under settings, select Inbound security rules.
  • Select + Add.
  • Change the Destination port ranges from 8080 to 22.
  • Select TCP for the protocol.
  • Set the name to ftpInbound.
  • Select Add.
  • Select Home to return to the Azure portal home page.

Create an inbound security rule.


Step 4: Associate a network security group to the subnet.

  • From the Azure portal home page, in the search box, enter virtual networks.
  • Select virtual networks under services.
  • Select the management-tasks-vnetvirtual network.
  • Under settings, select Subnets.
  • Select the ftpSubnet you created.
  • On the Edit subnet page, under the Security section heading, update the Network security group field to ftpNSG.
  • Select Save.

Associate the NSG to the subnet.


Conclusion

Congratulations! you have successfully completed configuring your virtual network for Azure management tasks by creating a subnet for SFTP traffic and setting up an NSG (network security group) to control the incoming traffic and security. Now let us move to the next part of the series, where we manage our VM (virtual machine).


Thank you for reading my blog. 😊😊

If you need further assistance, feel free to reach out in the comments or hit me up on Twitter. You can also follow me on GitHub. My DMs are open, and love discussions on cloud topics as always! 😁

Oluwatofunmi Emmanuel Oluwaloseyi

Top comments (0)