2

Google documentation says that If you have multiple services running on a VM, you may want to assign each one a different internal IP address. You can do this with Alias IP ranges.

I'm new to networking and I have followed the steps on the below document and created Alias IP Ranges, but I couldn't figure out how to assign an application to the internal IP that I have created?

https://cloud.google.com/compute/docs/alias-ip/configure-alias-ip-ranges

Dharman
  • 30,962
  • 25
  • 85
  • 135
Pasta
  • 53
  • 5
  • If you are using socket, 0.0.0.0: means listen on all IPs of this machine, : will make it listen on a specific IP. Note that : doesn't work on GCE for the way it implements external IP. – Dagang Nov 02 '17 at 21:31

1 Answers1

0

Once an alias IP range is assigned to a GCE instance, network services can be started on that instance listening on any IP address from the alias IP range, for example:

# Start listening on an IP address from the 10.128.1.0/24 alias IP range
netcat -l -p 8888 -s 10.128.1.12 -v

# Establish a test connection (same VM, different pane/tab)
netcat 10.128.1.12 8888 <<< “test connection”
golem
  • 1,820
  • 1
  • 20
  • 25