I’m playing with the new Nomad (as opposed to Consul) service discovery. Perhaps someone can help me sift through the particulars here?
I have a Postgres Docker container which is a task in a group with several other tasks/containers. The group is configured for network="bridge"
and CNI plugins are installed and working. When I define the service and check like so:
...
service {
provider = "nomad"
name = "postgres"
port = "postgres"
check {
type = "tcp"
port = "postgres"
interval = "10s"
timeout = "2s"
}
}
...
The alloc in the Nomad UI shows that the IP address of the service is the configured advertise address. However if I exec into the container I and look at =/proc/net/fib_trie= I see an IP address for the container which is in the usual Docker 172.26.x.x address space.
I would expect the Nomad UI to show the IP address in the Docker bridge address space and not the advertise address unless perhaps I had Postgres port (tcp/5432) configured in the port map for the Job.
Thoughts?