# Install on Azure

### Create a virtual machine

#### Basic Settings

* From the Azure Service select "Virtual Machines".
* Click on Create > Virtual Machine
* Select an existing resource group or create a new one. If don't know what resource groups are, create a new one called `rport`.This avoids conflicts with existing resource groups.
* Enter `rport-server` as the name for the virtual machine.
* Select a region near you.
* Select "No infrastructure redundancy required" for the availability options.
* From the Image drop-down select `Debian 11 "Bullseye" - Gen 1`.

  You might need to click on "See all images" and type in "debian bullseye" into the search field.
* On the size-drop-down click "See all sizes" to get access to the cheap options.\
  It's a bit challenging to find cheap VMs. \
  Use the filters to display only VMs with 1-2 CPUs and 0-2GB RAM.\
  Select a `B1` or `B1ls` series (\~3-7€/month)

![](https://1574570054-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MekeI9EovpQqbUTQSdM%2F-Mf31Iw_Clvp7N1HOICW%2F-Mf36z_x4F-IF78SUifF%2Fimage.png?alt=media\&token=51fe5317-a7c1-4525-8006-ba7c428ea0b5)

* If you have SSH key pair, use it. Otherwise, select "Password" as the authentication type.
* Select a username other than `root` or `admin`. For example, `superuser`.
* Enter a strong password, if you are not using SSH keys.
* Do not change the inbound ports.
* Proceed to the next step, "Discs". Do not change anything and proceed to next step "Networking".

![Basic details of the new virtual machine](https://1574570054-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MekeI9EovpQqbUTQSdM%2Fuploads%2FBRjcmp6IJVjqJVkae7s9%2Fazure-create-vm.png?alt=media\&token=5388863b-7ca7-4f54-b340-79b4668e40d7)

#### Networking

On the networking setup, select "Advanced" for the NIC network security group" and click "Create New" to create a new security group.

![You need an advanced setup.](https://1574570054-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MekeI9EovpQqbUTQSdM%2F-Mf31Iw_Clvp7N1HOICW%2F-Mf39Y5xJv0vJGA6HmFt%2Fimage.png?alt=media\&token=6c1ea13f-ad6d-44c1-9c49-68d31f4c11aa)

When creating the new network security group, add the following new inbound rules.

| Source | Src Port Ra | Dest. | Service | Dest.Port Ra  | Protocol | Action | Prio | Name         |
| ------ | ----------- | ----- | ------- | ------------- | -------- | ------ | ---- | ------------ |
| Any    | \*          | Any   | HTTP    | `80`          | TCP      | Allow  | 1010 | Port\_80     |
| Any    | \*          | Any   | HTTPS   | `443`         | TCP      | Allow  | 1020 | Port\_443    |
| Any    | \*          | Any   | Custom  | `20000-30000` | TCP      | Allow  | 1030 | Port\_20-30k |
| Any    | \*          | Any   | Custom  | `*`           | ICMP     | Allow  | 1040 | Ping         |

{% hint style="warning" %}
Do not skip the ICMP rule. Your virtual machines must respond to ICMP echo requests.👆
{% endhint %}

![](https://1574570054-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MekeI9EovpQqbUTQSdM%2F-Mf31Iw_Clvp7N1HOICW%2F-Mf3BqK5quJfqozDzaEl%2Fimage.png?alt=media\&token=7627ea07-f4ad-4930-a91c-fddf3e75cd08)

Now proceed to all the next steps without changing the pre-filled defaults.

Finally, create the new virtual machine.&#x20;

After the machine has been created, click on "Go to resource" to get access to all details of the virtual machine.

### Install the RPort server on your new Azure Virtual Server

From the details of the newly created virtual machine, grab the public IP address.

![Grab the IP address](https://1574570054-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MekeI9EovpQqbUTQSdM%2F-Mf31Iw_Clvp7N1HOICW%2F-Mf3Dk1J7D3VBS69bFcY%2Fimage.png?alt=media\&token=de6792df-5ba8-42f0-8e30-3238d0210bd3)

Connect over SSH to the instance using the username you specified during the VM creation. For example, ssh `superuser@20.185.220.116`. After the login, type in `sudo -i` to change to the root account.

👉 Now proceed to [Install RPort on any virgin cloud VM](https://kb.rport.io/install-the-rport-server/install-rport-on-any-virgin-cloud-vm)
