runtime

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2022 License: Apache-2.0 Imports: 51 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Apiserver

type Apiserver struct {
	LogPath string
	Options *apiserver.ApiserverOptions
	// contains filtered or unexported fields
}

func NewApiserver

func NewApiserver(ctx context.Context, opt *apiserver.ApiserverOptions, logPath string) *Apiserver

func (*Apiserver) Run

func (s *Apiserver) Run() error

start run in routine and no wait

type ControllerManager

type ControllerManager struct {
	LogPath string
	Options *controllermanager.ControllerManagerOptions
	// contains filtered or unexported fields
}

func (*ControllerManager) Run

func (s *ControllerManager) Run(kubeAdminPath string) error

start run in routine and no wait

func (*ControllerManager) WaitForAPIServer

func (s *ControllerManager) WaitForAPIServer(ctx context.Context, kubeAdminPath string) error

type KineServer

type KineServer struct {
	LogPath     string
	DBPath      string
	BindAddress string
	Port        uint16
	CAPath      string
	CertPath    string
	KeyPath     string
	// contains filtered or unexported fields
}

func NewKineServer

func NewKineServer(ctx context.Context, opt *kine.KineOptions, dbPath string, logPath string) *KineServer

func (*KineServer) Run

func (s *KineServer) Run() error

start run in routine and no wait

type KubernatesServer

type KubernatesServer struct {
	ApiserverOptions  *apiserver.ApiserverOptions
	ControllerOptions *controllermanager.ControllerManagerOptions
	SchedulerOptions  *scheduler.SchedulerOptions
	KubeAdminPath     string
	// contains filtered or unexported fields
}

func NewKubernatesServer

func NewKubernatesServer(ctx context.Context, apiserverOptions *apiserver.ApiserverOptions, controllerOptions *controllermanager.ControllerManagerOptions, schedulerOptions *scheduler.SchedulerOptions, kubeAdminPath string, logPath string) *KubernatesServer

func (*KubernatesServer) Run

func (s *KubernatesServer) Run() error

start run in routine and no wait

func (*KubernatesServer) RunAfter

func (s *KubernatesServer) RunAfter() error

type LiteKubeControl

type LiteKubeControl struct {
	BindAddress string
	BindPort    uint16

	NetworkClient      *NetWorkRegisterClient
	AuthFile           string
	LocalHostNodeToken string

	BufferPath                string
	EndPoint                  string
	ValidateApiserverServerCA string
	ValidateApiserverClientCA string
	SignalKubeletServerCert   string
	SignalKubeletServerKey    string
	SignalApiserverClientCert string
	SignalApiserverClientKey  string
	AuthTokenFile             string
	ClusterCIDR               string
	ServiceClusterIpRange     string
	ClusterDNS                string

	ValidateApiserverServerCABase64 string
	ValidateApiserverClientCABase64 string
	CacheClientCertPath             string
	CacheClientKeyPath              string
	CacheServerCertPath             string
	CacheServerKeyPath              string
	Token                           string
	// contains filtered or unexported fields
}

func NewLiteKubeControl

func NewLiteKubeControl(ctx context.Context, networkClient *NetWorkRegisterClient, bufferPath string, nodeToken string, endpoint string, validateApiserverServerCA string, validateApiserverClientCA string, signalKubeletServerCert string, signalKubeletServerKey string, signalApiserverClientCert string, signalApiserverClientKey string, authTokenFile string, clusterCIDR string, serviceClusterIpRange string) *LiteKubeControl

func (*LiteKubeControl) BootStrapKubeProxy

func (*LiteKubeControl) BootStrapKubelet

func (*LiteKubeControl) BootStrapNetwork

func (*LiteKubeControl) BootstrapValidateKubeApiserverClient

func (s *LiteKubeControl) BootstrapValidateKubeApiserverClient(ctx context.Context, in *control.NoneValue) (*control.BootstrapValidateKubeApiserverClientResponse, error)

func (*LiteKubeControl) CheckHealth

func (*LiteKubeControl) CreateToken

func (*LiteKubeControl) DeleteToken

func (*LiteKubeControl) Init

func (s *LiteKubeControl) Init() error

func (*LiteKubeControl) NodeToken

func (*LiteKubeControl) QueryTokens

func (*LiteKubeControl) Run

func (s *LiteKubeControl) Run() error

func (*LiteKubeControl) TokenInterceptor

func (s *LiteKubeControl) TokenInterceptor() func(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error)

type NetWorkControllerServer

type NetWorkControllerServer struct {
	LogDir  string
	TLSDir  string
	WorkDir string

	// register
	RegisterBindAddress string
	RegisterPort        uint16
	RegisterCACert      string
	RegisterCAKey       string
	RegisterServerCert  string
	RegisterServerkey   string

	// join
	JoinBindAddress string
	JoinPort        uint16
	JoinCACert      string
	JoinCAKey       string
	JoinServerCert  string
	JoinServerkey   string
	// contains filtered or unexported fields
}

func (*NetWorkControllerServer) Run

func (s *NetWorkControllerServer) Run() error

start run in routine and no wait

type NetWorkJoinClient

type NetWorkJoinClient struct {
	WorkDir     string
	TLSDir      string
	LogDir      string
	BindAddress string
	Port        uint16
	CAPath      string
	CertPath    string
	KeyPath     string
	NodeToken   string
	// contains filtered or unexported fields
}

func NewNetWorkJoinClient

func NewNetWorkJoinClient(ctx context.Context, opt *netmanager.NetManagerOptions, workDir string, tlsDir string, logDir string) *NetWorkJoinClient

func (*NetWorkJoinClient) Run

func (s *NetWorkJoinClient) Run() error

start run in routine and no wait

type NetWorkRegisterClient

type NetWorkRegisterClient struct {
	BindAddress     string
	Port            uint16
	CAPath          string
	CertPath        string
	KeyPath         string
	NodeToken       string
	NCClient        *grpc_client.GrpcClient
	BootstrapClient *grpc_client.GrpcBootStrapClient
	// contains filtered or unexported fields
}

func (*NetWorkRegisterClient) CreateBootStrapToken

func (c *NetWorkRegisterClient) CreateBootStrapToken(life int64) (string, error)

func (*NetWorkRegisterClient) GetBootStrapAddress

func (c *NetWorkRegisterClient) GetBootStrapAddress() (string, error)

func (*NetWorkRegisterClient) GetBootStrapPort

func (c *NetWorkRegisterClient) GetBootStrapPort() (uint16, error)

func (*NetWorkRegisterClient) QueryIp

func (c *NetWorkRegisterClient) QueryIp() (string, error)

query local ip

func (*NetWorkRegisterClient) QueryIpByToken

func (c *NetWorkRegisterClient) QueryIpByToken(nodeToken string) (string, error)

query ip by node-token

type Scheduler

type Scheduler struct {
	LogPath string
	Options *scheduler.SchedulerOptions
	// contains filtered or unexported fields
}

func NewScheduler

func NewScheduler(ctx context.Context, opt *scheduler.SchedulerOptions, logPath string) *Scheduler

func (*Scheduler) Run

func (s *Scheduler) Run() error

start run in routine and no wait

type TokenDesc

type TokenDesc struct {
	Token      string
	CreateBy   string
	CreateTime string
	Life       int64
	IsAdmin    bool
	IsValid    bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL