When attempting to use environment variables, as specified in the Nomad documentation, to configure Nomad Jobs, I am encountering challenges. Despite running my Nomad Cluster within a private network configuration, each node in the cluster also has a network interface connected to the public internet.
As an illustration, a portion of my master instance configuration appears as follows:
hcl
bind_addr = "10.7.230.11"
server {
enabled = true
bootstrap_expect = 3
}
advertise {
http = "10.7.230.11"
serf = "10.7.230.11"
rpc = "10.7.230.11"
}
Despite this configuration specifying private network IP addresses, when attempting to use environment variables such as IP_ADDR_{port} (e.g., IP_ADDR_http), Nomad uses the public IP address of the node instead of the private one. Where do i need to apply changes so Nomad uses the private addresses of the nodes instead of the public addresses.
Thanks in advance ![]()