fn: SSL config adjustments (#1160)

SSL related FN_NODE_CERT (and related) settings are
not very clear today. Removing this in favor of a
simple map of tls.Config objects. Three keys are
provided for this map:

TLSGRPCServer
TLSAdminServer
TLSWebServer

which correspond to server TLS settings for the
associated services.

Operators/implementers can further add more
keys to the map and add their own TLS config.
This commit is contained in:
Tolga Ceylan
2018-08-06 20:57:03 -07:00
committed by GitHub
parent ff39d0896f
commit f57571fb3a
9 changed files with 157 additions and 175 deletions

View File

@@ -2,6 +2,7 @@ package agent
import (
"context"
"crypto/tls"
"errors"
"testing"
@@ -9,7 +10,7 @@ import (
)
func setupStaticPool(runners []string) pool.RunnerPool {
return NewStaticRunnerPool(runners, nil, "", mockRunnerFactory)
return NewStaticRunnerPool(runners, nil, mockRunnerFactory)
}
var (
@@ -36,7 +37,7 @@ func (r *mockStaticRunner) Address() string {
return r.address
}
func mockRunnerFactory(addr, cn string, pki *pool.PKIData) (pool.Runner, error) {
func mockRunnerFactory(addr string, tlsConf *tls.Config) (pool.Runner, error) {
return &mockStaticRunner{address: addr}, nil
}