mirror of
https://github.com/status-im/consul.git
synced 2025-01-10 22:06:20 +00:00
Add the connect.enable_serverless_plugin
configuration option.
This commit is contained in:
parent
abfcde1bc6
commit
3302b2eec2
@ -669,6 +669,7 @@ func (b *builder) build() (rt RuntimeConfig, err error) {
|
|||||||
connectEnabled := boolVal(c.Connect.Enabled)
|
connectEnabled := boolVal(c.Connect.Enabled)
|
||||||
connectCAProvider := stringVal(c.Connect.CAProvider)
|
connectCAProvider := stringVal(c.Connect.CAProvider)
|
||||||
connectCAConfig := c.Connect.CAConfig
|
connectCAConfig := c.Connect.CAConfig
|
||||||
|
serverlessPluginEnabled := boolVal(c.Connect.EnableServerlessPlugin)
|
||||||
|
|
||||||
// autoEncrypt and autoConfig implicitly turns on connect which is why
|
// autoEncrypt and autoConfig implicitly turns on connect which is why
|
||||||
// they need to be above other settings that rely on connect.
|
// they need to be above other settings that rely on connect.
|
||||||
@ -979,6 +980,7 @@ func (b *builder) build() (rt RuntimeConfig, err error) {
|
|||||||
ConnectCAProvider: connectCAProvider,
|
ConnectCAProvider: connectCAProvider,
|
||||||
ConnectCAConfig: connectCAConfig,
|
ConnectCAConfig: connectCAConfig,
|
||||||
ConnectMeshGatewayWANFederationEnabled: connectMeshGatewayWANFederationEnabled,
|
ConnectMeshGatewayWANFederationEnabled: connectMeshGatewayWANFederationEnabled,
|
||||||
|
ConnectServerlessPluginEnabled: serverlessPluginEnabled,
|
||||||
ConnectSidecarMinPort: sidecarMinPort,
|
ConnectSidecarMinPort: sidecarMinPort,
|
||||||
ConnectSidecarMaxPort: sidecarMaxPort,
|
ConnectSidecarMaxPort: sidecarMaxPort,
|
||||||
ConnectTestCALeafRootChangeSpread: b.durationVal("connect.test_ca_leaf_root_change_spread", c.Connect.TestCALeafRootChangeSpread),
|
ConnectTestCALeafRootChangeSpread: b.durationVal("connect.test_ca_leaf_root_change_spread", c.Connect.TestCALeafRootChangeSpread),
|
||||||
|
@ -612,6 +612,7 @@ type Connect struct {
|
|||||||
CAProvider *string `mapstructure:"ca_provider"`
|
CAProvider *string `mapstructure:"ca_provider"`
|
||||||
CAConfig map[string]interface{} `mapstructure:"ca_config"`
|
CAConfig map[string]interface{} `mapstructure:"ca_config"`
|
||||||
MeshGatewayWANFederationEnabled *bool `mapstructure:"enable_mesh_gateway_wan_federation"`
|
MeshGatewayWANFederationEnabled *bool `mapstructure:"enable_mesh_gateway_wan_federation"`
|
||||||
|
EnableServerlessPlugin *bool `mapstructure:"enable_serverless_plugin"`
|
||||||
|
|
||||||
// TestCALeafRootChangeSpread controls how long after a CA roots change before new leaft certs will be generated.
|
// TestCALeafRootChangeSpread controls how long after a CA roots change before new leaft certs will be generated.
|
||||||
// This is only tuned in tests, generally set to 1ns to make tests deterministic with when to expect updated leaf
|
// This is only tuned in tests, generally set to 1ns to make tests deterministic with when to expect updated leaf
|
||||||
|
@ -486,6 +486,12 @@ type RuntimeConfig struct {
|
|||||||
// and servers in a cluster for correct connect operation.
|
// and servers in a cluster for correct connect operation.
|
||||||
ConnectEnabled bool
|
ConnectEnabled bool
|
||||||
|
|
||||||
|
// ConnectServerlessPluginEnabled opts the agent into the serverless plugin.
|
||||||
|
// This plugin allows services to be configured as AWS Lambdas. After the
|
||||||
|
// Lambda service is configured, Connect services can invoke the Lambda
|
||||||
|
// service like any other upstream.
|
||||||
|
ConnectServerlessPluginEnabled bool
|
||||||
|
|
||||||
// ConnectSidecarMinPort is the inclusive start of the range of ports
|
// ConnectSidecarMinPort is the inclusive start of the range of ports
|
||||||
// allocated to the agent for asigning to sidecar services where no port is
|
// allocated to the agent for asigning to sidecar services where no port is
|
||||||
// specified.
|
// specified.
|
||||||
|
@ -5538,6 +5538,7 @@ func TestLoad_FullConfig(t *testing.T) {
|
|||||||
"CSRMaxConcurrent": float64(2),
|
"CSRMaxConcurrent": float64(2),
|
||||||
},
|
},
|
||||||
ConnectMeshGatewayWANFederationEnabled: false,
|
ConnectMeshGatewayWANFederationEnabled: false,
|
||||||
|
ConnectServerlessPluginEnabled: true,
|
||||||
DNSAddrs: []net.Addr{tcpAddr("93.95.95.81:7001"), udpAddr("93.95.95.81:7001")},
|
DNSAddrs: []net.Addr{tcpAddr("93.95.95.81:7001"), udpAddr("93.95.95.81:7001")},
|
||||||
DNSARecordLimit: 29907,
|
DNSARecordLimit: 29907,
|
||||||
DNSAllowStale: true,
|
DNSAllowStale: true,
|
||||||
|
@ -127,6 +127,7 @@
|
|||||||
"ConnectCAProvider": "",
|
"ConnectCAProvider": "",
|
||||||
"ConnectEnabled": false,
|
"ConnectEnabled": false,
|
||||||
"ConnectMeshGatewayWANFederationEnabled": false,
|
"ConnectMeshGatewayWANFederationEnabled": false,
|
||||||
|
"ConnectServerlessPluginEnabled": false,
|
||||||
"ConnectSidecarMaxPort": 0,
|
"ConnectSidecarMaxPort": 0,
|
||||||
"ConnectSidecarMinPort": 0,
|
"ConnectSidecarMinPort": 0,
|
||||||
"ConnectTestCALeafRootChangeSpread": "0s",
|
"ConnectTestCALeafRootChangeSpread": "0s",
|
||||||
|
1
agent/config/testdata/full-config.hcl
vendored
1
agent/config/testdata/full-config.hcl
vendored
@ -210,6 +210,7 @@ connect {
|
|||||||
}
|
}
|
||||||
enable_mesh_gateway_wan_federation = false
|
enable_mesh_gateway_wan_federation = false
|
||||||
enabled = true
|
enabled = true
|
||||||
|
enable_serverless_plugin = true
|
||||||
}
|
}
|
||||||
gossip_lan {
|
gossip_lan {
|
||||||
gossip_nodes = 6
|
gossip_nodes = 6
|
||||||
|
3
agent/config/testdata/full-config.json
vendored
3
agent/config/testdata/full-config.json
vendored
@ -209,7 +209,8 @@
|
|||||||
"csr_max_concurrent": 2
|
"csr_max_concurrent": 2
|
||||||
},
|
},
|
||||||
"enable_mesh_gateway_wan_federation": false,
|
"enable_mesh_gateway_wan_federation": false,
|
||||||
"enabled": true
|
"enabled": true,
|
||||||
|
"enable_serverless_plugin": true
|
||||||
},
|
},
|
||||||
"gossip_lan" : {
|
"gossip_lan" : {
|
||||||
"gossip_nodes": 6,
|
"gossip_nodes": 6,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user