Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // Port is the listened port for client server Port int // PeerPort is the listened port for peer server PeerPort int // InfoPort is the listened port for info server InfoPort int // ClientSecurityConfig is the security config for client server ClientSecurityConfig *SecurityConfig // PeerSecurityConfig is the security config for peer server PeerSecurityConfig *SecurityConfig // EnableEtcdCompatibility is the flag if KubeWharf should try to be compatible with etcd3 EnableEtcdCompatibility bool }
type Endpoint ¶
type Endpoint struct {
// contains filtered or unexported fields
}
Endpoint is the endpoint for serving
func NewEndpoint ¶
NewEndpoint returns an Endpoint for serving
func (*Endpoint) Run ¶
Run start grpc and http server, and block until there is any error
each port may start secure server and insecure server ClientPort─┬─ Secure(TLS) ─┬─ GRPC │ └─ HTTP │ └─ Insecure ─┬─ GRPC └─ HTTP PeerPort ─┬─ Secure(TLS) ─┬─ GRPC │ └─ HTTP │ └─ Insecure ─┬─ GRPC └─ HTTP InfoPort ─── Insecure ─── HTTP
type SecurityConfig ¶
type SecurityConfig struct { // CertFile is the file path of server's cert CertFile string // KeyFile is the file path of server's private key KeyFile string // CA is the file path of ca's cert CA string // ClientAuth indicate if client certs should be verified ClientAuth bool // AllowInsecure indicates if server can be access in insecure mode without tls AllowInsecure bool // contains filtered or unexported fields }
SecurityConfig is the configuration of server tls
func (*SecurityConfig) ToKvs ¶
func (sc *SecurityConfig) ToKvs() []interface{}
ToKvs make config to kvs for klog
Click to show internal directories.
Click to hide internal directories.