consul/connect: enable setting local_bind_address in upstream
This commit is contained in:
parent
f45fc6c899
commit
30c840e88e
|
@ -5,6 +5,8 @@ BUG FIXES:
|
|||
* cli: Fixed a bug where non-int proxy port would panic CLI [[GH-10072](https://github.com/hashicorp/nomad/issues/10072)]
|
||||
* cli: Fixed a bug where `nomad operator debug` incorrectly parsed https Consul API URLs. [[GH-10082](https://github.com/hashicorp/nomad/pull/10082)]
|
||||
|
||||
IMPROVEMENTS:
|
||||
* consul/connect: Enable setting `local_bind_address` field on connect upstreams [[GH-6248](https://github.com/hashicorp/nomad/issues/6248)]
|
||||
## 1.0.4 (February 24, 2021)
|
||||
|
||||
FEATURES:
|
||||
|
|
|
@ -147,6 +147,7 @@ func interpolateConnectSidecarService(taskEnv *TaskEnv, sidecar *structs.ConsulS
|
|||
for i := 0; i < len(sidecar.Proxy.Upstreams); i++ {
|
||||
sidecar.Proxy.Upstreams[i].Datacenter = taskEnv.ReplaceEnv(sidecar.Proxy.Upstreams[i].Datacenter)
|
||||
sidecar.Proxy.Upstreams[i].DestinationName = taskEnv.ReplaceEnv(sidecar.Proxy.Upstreams[i].DestinationName)
|
||||
sidecar.Proxy.Upstreams[i].LocalBindAddress = taskEnv.ReplaceEnv(sidecar.Proxy.Upstreams[i].LocalBindAddress)
|
||||
}
|
||||
sidecar.Proxy.Config = interpolateMapStringInterface(taskEnv, sidecar.Proxy.Config)
|
||||
}
|
||||
|
|
|
@ -169,6 +169,7 @@ func TestInterpolate_interpolateConnect(t *testing.T) {
|
|||
"address1": "1.2.3.4",
|
||||
"destination1": "_dest1",
|
||||
"datacenter1": "_datacenter1",
|
||||
"localbindaddress1": "127.0.0.2",
|
||||
"path1": "_path1",
|
||||
"protocol1": "_protocol1",
|
||||
"port2": "_port2",
|
||||
|
@ -214,6 +215,7 @@ func TestInterpolate_interpolateConnect(t *testing.T) {
|
|||
DestinationName: "${destination1}",
|
||||
Datacenter: "${datacenter1}",
|
||||
LocalBindPort: 10001,
|
||||
LocalBindAddress: "${localbindaddress1}",
|
||||
}},
|
||||
Expose: &structs.ConsulExposeConfig{
|
||||
Paths: []structs.ConsulExposePath{{
|
||||
|
@ -321,6 +323,7 @@ func TestInterpolate_interpolateConnect(t *testing.T) {
|
|||
DestinationName: "_dest1",
|
||||
Datacenter: "_datacenter1",
|
||||
LocalBindPort: 10001,
|
||||
LocalBindAddress: "127.0.0.2",
|
||||
}},
|
||||
Expose: &structs.ConsulExposeConfig{
|
||||
Paths: []structs.ConsulExposePath{{
|
||||
|
|
Loading…
Reference in New Issue