Inbound Network Address Translation (NAT) allows you to map internet traffic to a public-facing IP address and port to a private IP address and port inside your SDDC's compute network.

About this task

When configuring NAT rules, you have the option of configuring either one-to-one NAT or one-to-many NAT. Use one-to-one NAT when you want to map a single public IP address and port to a single internal IP address and port. For example, a public IP of 198.51.100.5 and port 443 is mapped to 172.100.100.20 and port 443. In some cases, you might choose to map a source port to a different destination port. For example, 198.51.100.5 and port 80 might be mapped to 172.100.100.20 and port 8080.

Use one-to-many NAT when a single public IP address and port is mapped to one internal IP address and multiple ports, or to multiple internal IP addresses and ports.

Prerequisites

Before you can assign a public IP address to a virtual machine, you must assign the virtual machine to a logical network and give it a static IP address.

Procedure

  1. Log in to the VMC Console at https://vmc.vmware.com.
  2. Click View Details on the SDDC card.
  3. Click Network.
  4. Under Compute Gateway, click NAT.
  5. Click Add NAT Rule.
  6. Enter the NAT parameters.

    Option

    Description

    Description

    Enter a description for the NAT rule.

    Public IP

    Select the Public IP address you have provisioned for the VM.

    Service

    Select one of the following.

    • Select Any for a rule that applies to all inbound traffic.

    • Select a particular service to create a rule that applies only to traffic using that protocol and port.

    • Select Custom TCP, Custom UDP, or ICMP (All ICMP) to create a rule that applies to a service and/or port that is not available in the dropdown menu.

    Public Ports

    If you selected a custom TCP or UDP, enter the port to use for that service.

    Internal IP

    Enter the internal (private) IP address to direct the traffic from the public address to.

    Internal Ports

    If you selected a custom TCP or UDP, enter the port to use for that service.

  7. Click Save.