Assigning a Public IP Address to a VM¶
If you want to be able to access your VMs over a port other than 22/TCP, 80/TCP and 443/TCP (used for ssh, http, and https, respectively) over the public internet (as opposed from a VM on the same Cloud&Heat deployment) you need to assign a public IP address to your VM instance.
Assigning a public IP address to a VM is done as follows:
- Allocate a public IP address to your project.
- Associate the public IP address assigned to your project with your running VM.
Step 1: Allocating public IP to project¶
- Select the Access & Security tab in the Cloud&Heat Dashboard.
- Select the Floating IPs tab at the top, as shown in Figure 11: Access & Security -> Floating IPs tab.
- Click the Allocate IP To Project button, as shown in Figure 12: Allocate Floating IP dialog window.
- Select a pool from the dropdown menu and press the Allocate IP button.
- A public IP address has now been allocated to your project and is listed in the table under the Floating IPs tab. In the case that there are no more public IPs in the selected pool, there will be an error message indicating that the allocation failed. If this is the case select another pool from the dropdown menu in the previous step, or try again later.
Step 2: Associating public IP address with instance¶
- Press the Associate button to the right of the IP address in the table under the Floating IPs tab. A dialog window will appear, as shown in Figure 13: Manage Floating IP Associations.
- Make sure the desired IP address is selected in the IP Address dropdown menu.
- Select the instance with which the IP address should be associated from the list under Instance to be associated.
- Click the Associate button in the dialog window.
- The selected instance will now appear in the Instance column in the table under the Floating IPs tab. Furthermore, the IP address will appear in the IP Address column of the selected instance in the table under the Instances tab.