Fixup agent/config tests

Signed-off-by: Mark Anderson <manderson@hashicorp.com>
This commit is contained in:
Mark Anderson 2021-05-04 18:30:20 -07:00
parent ab0b90d480
commit ac4cb213a1
4 changed files with 19 additions and 7 deletions

View File

@ -5648,6 +5648,13 @@ func TestLoad_FullConfig(t *testing.T) {
LocalBindPort: 11884,
LocalBindAddress: "127.24.88.0",
},
{
DestinationType: "prepared_query",
DestinationNamespace: "9nakw0td",
DestinationName: "placeholder",
LocalBindSocketPath: "/foo/bar/upstream",
LocalBindSocketMode: "0600",
},
},
Expose: structs.ExposeConfig{
Checks: true,

View File

@ -325,6 +325,7 @@
"Name": "foo",
"Port": 0,
"Proxy": null,
"SocketPath": "",
"TaggedAddresses": {},
"Tags": [],
"Token": "hidden",

View File

@ -362,7 +362,6 @@ service = {
address = "cOlSOhbp"
token = "msy7iWER"
port = 24237
socket_path = "/tmp/rc78ap"
weights = {
passing = 100,
warning = 1
@ -456,7 +455,6 @@ services = [
address = "9RhqPSPB"
token = "myjKJkWH"
port = 72219
socket_path = "/foo/bar/sock_7IszXMQ1"
enable_tag_override = true
check = {
id = "qmfeO5if"
@ -563,7 +561,6 @@ services = [
destination_service_id = "6L6BVfgH-id"
local_service_address = "127.0.0.2"
local_service_port = 23759
local_service_socket_path = "/foo/bar/local"
config {
cedGGtZf = "pWrUNiWw"
}
@ -581,6 +578,11 @@ services = [
destination_name = "KSd8HsRl"
local_bind_port = 11884
local_bind_address = "127.24.88.0"
},
{
destination_type = "prepared_query"
destination_namespace = "9nakw0td"
destination_name = "placeholder"
local_bind_socket_path = "/foo/bar/upstream"
local_bind_socket_mode = "0600"
},

View File

@ -358,7 +358,6 @@
"address": "cOlSOhbp",
"token": "msy7iWER",
"port": 24237,
"socket_path": "/tmp/rc78ap",
"weights": {
"passing": 100,
"warning": 1
@ -453,7 +452,6 @@
"address": "9RhqPSPB",
"token": "myjKJkWH",
"port": 72219,
"socket_path":"/foo/bar/sock_7IszXMQ1",
"enable_tag_override": true,
"check": {
"id": "qmfeO5if",
@ -563,7 +561,6 @@
"destination_service_name": "6L6BVfgH",
"local_service_address": "127.0.0.2",
"local_service_port": 23759,
"local_service_socket_path": "/foo/bar/local",
"expose": {
"checks": true,
"paths": [
@ -592,7 +589,12 @@
"destination_namespace": "9nakw0td",
"destination_type": "prepared_query",
"local_bind_address": "127.24.88.0",
"local_bind_port": 11884,
"local_bind_port": 11884
},
{
"destination_name": "placeholder",
"destination_namespace": "9nakw0td",
"destination_type": "prepared_query",
"local_bind_socket_path": "/foo/bar/upstream",
"local_bind_socket_mode": "0600"
}