customcluster

package
v0.0.0-...-8a20bae Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2022 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Host           string
	Port           int
	ApiServer      string
	AgentToken     string
	ClusterID      string
	ControllerMode bool
	AgentMode      bool
)
View Source
var (
	HeartbeatIntervalSeconds = 10
	HeartbeatTimeoutSeconds  = 30
)

Cluster lifecycle

Functions

This section is empty.

Types

type Agent

type Agent struct {
	// contains filtered or unexported fields
}

func NewAgent

func NewAgent() (*Agent, error)

func (*Agent) Run

func (a *Agent) Run(stopCh chan struct{}) error

type Driver

type Driver struct {
	Client   client.Client
	Cluster  *hackathonv1.CustomCluster
	Recorder record.EventRecorder
	Log      logr.Logger
}

func (*Driver) InitCustomCluster

func (d *Driver) InitCustomCluster(ctx context.Context, status *Status) *results.Results

func (*Driver) Reconcile

func (d *Driver) Reconcile(ctx context.Context, status *Status) *results.Results

type Server

type Server struct {
}

func (*Server) BuildLatestCommand

func (s *Server) BuildLatestCommand() (*types.Command, error)

func (*Server) GetClusterInfo

func (s *Server) GetClusterInfo(status types.ClusterStatus) (*v1.CustomCluster, types.ClusterStatus, error)

func (*Server) HandleHeartbeat

func (s *Server) HandleHeartbeat(hb *types.Heartbeat) (resp *types.HeartbeatResponse, err error)

type Status

type Status struct {
	*event.Recorder
	Cluster *hackathonv1.CustomCluster
	Status  *hackathonv1.CustomClusterStatus
}

func NewStatus

func NewStatus(cluster *hackathonv1.CustomCluster) *Status

func (*Status) Apply

func (s *Status) Apply() ([]event.Event, *hackathonv1.CustomCluster)

Jump to

Keyboard shortcuts

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