mirror of https://github.com/hashicorp/consul
Formatting spaces between keys in Config entries (#8116)
* Formatting spaces between keys in Config entries * Service Router spacing * Missing Camel Case proxy-defaults * Remove extra spaces service-splitter * Remove extra spsaces service-resolver * More spaces a la hclfmt * Nice! * Oh joy! * More spaces on proxy-defaults * Update website/pages/docs/agent/config-entries/proxy-defaults.mdx Co-authored-by: Chris Piraino <cpiraino@hashicorp.com>pull/8126/head
parent
2c31673c03
commit
fb1f043cdc
|
@ -50,7 +50,7 @@ Name = "ingress-service"
|
||||||
|
|
||||||
Listeners = [
|
Listeners = [
|
||||||
{
|
{
|
||||||
Port = 3456
|
Port = 3456
|
||||||
Protocol = "tcp"
|
Protocol = "tcp"
|
||||||
Services = [
|
Services = [
|
||||||
{
|
{
|
||||||
|
@ -75,7 +75,7 @@ TLS {
|
||||||
|
|
||||||
Listeners = [
|
Listeners = [
|
||||||
{
|
{
|
||||||
Port = 8080
|
Port = 8080
|
||||||
Protocol = "http"
|
Protocol = "http"
|
||||||
Services = [
|
Services = [
|
||||||
{
|
{
|
||||||
|
@ -84,15 +84,15 @@ Listeners = [
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Port = 4567
|
Port = 4567
|
||||||
Protocol = "http"
|
Protocol = "http"
|
||||||
Services = [
|
Services = [
|
||||||
{
|
{
|
||||||
Name = "api"
|
Name = "api"
|
||||||
Hosts = ["foo.example.com"]
|
Hosts = ["foo.example.com"]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Name = "web"
|
Name = "web"
|
||||||
Hosts = ["website.example.com"]
|
Hosts = ["website.example.com"]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
@ -19,10 +19,10 @@ one global entry is supported.
|
||||||
Set the default protocol for all sidecar proxies in the default namespace:
|
Set the default protocol for all sidecar proxies in the default namespace:
|
||||||
|
|
||||||
```hcl
|
```hcl
|
||||||
kind = "proxy-defaults"
|
Kind = "proxy-defaults"
|
||||||
name = "global"
|
Name = "global"
|
||||||
namespace = "default"
|
Namespace = "default"
|
||||||
config {
|
Config {
|
||||||
protocol = "http"
|
protocol = "http"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@ -30,11 +30,11 @@ config {
|
||||||
Set proxy-specific defaults :
|
Set proxy-specific defaults :
|
||||||
|
|
||||||
```hcl
|
```hcl
|
||||||
kind = "proxy-defaults"
|
Kind = "proxy-defaults"
|
||||||
name = "global"
|
Name = "global"
|
||||||
config {
|
Config {
|
||||||
local_connect_timeout_ms = 1000
|
local_connect_timeout_ms = 1000
|
||||||
handshake_timeout_ms = 10000
|
handshake_timeout_ms = 10000
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
@ -17,10 +17,10 @@ service, such as its protocol.
|
||||||
Set the default protocol for a service in the default namespace to HTTP:
|
Set the default protocol for a service in the default namespace to HTTP:
|
||||||
|
|
||||||
```hcl
|
```hcl
|
||||||
Kind = "service-defaults"
|
Kind = "service-defaults"
|
||||||
Name = "web"
|
Name = "web"
|
||||||
Namespace = "default"
|
Namespace = "default"
|
||||||
Protocol = "http"
|
Protocol = "http"
|
||||||
```
|
```
|
||||||
|
|
||||||
## Available Fields
|
## Available Fields
|
||||||
|
|
|
@ -28,8 +28,8 @@ and discovery terminates.
|
||||||
Create service subsets based on a version metadata and override the defaults:
|
Create service subsets based on a version metadata and override the defaults:
|
||||||
|
|
||||||
```hcl
|
```hcl
|
||||||
Kind = "service-resolver"
|
Kind = "service-resolver"
|
||||||
Name = "web"
|
Name = "web"
|
||||||
DefaultSubset = "v1"
|
DefaultSubset = "v1"
|
||||||
Subsets = {
|
Subsets = {
|
||||||
"v1" = {
|
"v1" = {
|
||||||
|
@ -55,8 +55,8 @@ Redirect {
|
||||||
Enable failover for all subsets:
|
Enable failover for all subsets:
|
||||||
|
|
||||||
```hcl
|
```hcl
|
||||||
Kind = "service-resolver"
|
Kind = "service-resolver"
|
||||||
Name = "web"
|
Name = "web"
|
||||||
ConnectTimeout = "15s"
|
ConnectTimeout = "15s"
|
||||||
Failover = {
|
Failover = {
|
||||||
"*" = {
|
"*" = {
|
||||||
|
|
|
@ -77,7 +77,7 @@ Routes = [
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Destination {
|
Destination {
|
||||||
Service = "web"
|
Service = "web"
|
||||||
ServiceSubset = "canary"
|
ServiceSubset = "canary"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -93,7 +93,7 @@ Routes = [
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Destination {
|
Destination {
|
||||||
Service = "web"
|
Service = "web"
|
||||||
ServiceSubset = "canary"
|
ServiceSubset = "canary"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -48,11 +48,11 @@ Kind = "service-splitter"
|
||||||
Name = "web"
|
Name = "web"
|
||||||
Splits = [
|
Splits = [
|
||||||
{
|
{
|
||||||
Weight = 90
|
Weight = 90
|
||||||
ServiceSubset = "v1"
|
ServiceSubset = "v1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Weight = 10
|
Weight = 10
|
||||||
ServiceSubset = "v2"
|
ServiceSubset = "v2"
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
@ -65,7 +65,7 @@ Kind = "service-splitter"
|
||||||
Name = "web"
|
Name = "web"
|
||||||
Splits = [
|
Splits = [
|
||||||
{
|
{
|
||||||
Weight = 50
|
Weight = 50
|
||||||
# will default to service with same name as config entry ("web")
|
# will default to service with same name as config entry ("web")
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue