Documentation
¶
Overview ¶
Package binary implements the runtime.Runtime interface using the binaries.
Index ¶
- func BuildPrometheus(conf BuildPrometheusConfig) (string, error)
- func NewCluster(name, workdir string) (runtime.Runtime, error)
- type BuildPrometheusConfig
- type Cluster
- func (c *Cluster) AddContext(ctx context.Context, kubeconfigPath string) error
- func (c *Cluster) Available(ctx context.Context) error
- func (c *Cluster) CollectLogs(ctx context.Context, dir string) error
- func (c *Cluster) Down(ctx context.Context) error
- func (c *Cluster) EtcdctlInCluster(ctx context.Context, args ...string) error
- func (c *Cluster) Install(ctx context.Context) error
- func (c *Cluster) ListBinaries(ctx context.Context) ([]string, error)
- func (c *Cluster) ListImages(ctx context.Context) ([]string, error)
- func (c *Cluster) Logs(ctx context.Context, name string, out io.Writer) error
- func (c *Cluster) LogsFollow(ctx context.Context, name string, out io.Writer) error
- func (c *Cluster) Ready(ctx context.Context) (bool, error)
- func (c *Cluster) RemoveContext(ctx context.Context, kubeconfigPath string) error
- func (c *Cluster) SnapshotRestore(ctx context.Context, path string) error
- func (c *Cluster) SnapshotRestoreWithYAML(ctx context.Context, path string, filters []string) error
- func (c *Cluster) SnapshotSave(ctx context.Context, path string) error
- func (c *Cluster) SnapshotSaveWithYAML(ctx context.Context, path string, filters []string) error
- func (c *Cluster) Start(ctx context.Context) error
- func (c *Cluster) StartComponent(ctx context.Context, name string) error
- func (c *Cluster) Stop(ctx context.Context) error
- func (c *Cluster) StopComponent(ctx context.Context, name string) error
- func (c *Cluster) Uninstall(ctx context.Context) error
- func (c *Cluster) Up(ctx context.Context) error
- func (c *Cluster) WaitReady(ctx context.Context, timeout time.Duration) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildPrometheus ¶
func BuildPrometheus(conf BuildPrometheusConfig) (string, error)
BuildPrometheus builds the prometheus yaml content.
Types ¶
type BuildPrometheusConfig ¶
type BuildPrometheusConfig struct { ProjectName string SecurePort bool AdminCrtPath string AdminKeyPath string PrometheusPort uint32 EtcdPort uint32 KubeApiserverPort uint32 KubeControllerManagerPort uint32 KubeSchedulerPort uint32 KwokControllerPort uint32 }
BuildPrometheusConfig is the configuration for building the prometheus config
type Cluster ¶
Cluster is an implementation of Runtime for binary
func (*Cluster) AddContext ¶ added in v0.2.0
AddContext add the context of cluster to kubeconfig
func (*Cluster) CollectLogs ¶ added in v0.3.0
CollectLogs returns the logs of the specified component.
func (*Cluster) EtcdctlInCluster ¶ added in v0.1.0
EtcdctlInCluster implements the ectdctl subcommand
func (*Cluster) ListBinaries ¶
ListBinaries list binaries in the cluster
func (*Cluster) ListImages ¶
ListImages list images in the cluster
func (*Cluster) LogsFollow ¶
LogsFollow follows the logs of the component
func (*Cluster) RemoveContext ¶ added in v0.2.0
RemoveContext remove the context of cluster from kubeconfig
func (*Cluster) SnapshotRestore ¶
SnapshotRestore restore the snapshot of cluster
func (*Cluster) SnapshotRestoreWithYAML ¶ added in v0.2.0
SnapshotRestoreWithYAML restore the snapshot of cluster
func (*Cluster) SnapshotSave ¶
SnapshotSave save the snapshot of cluster
func (*Cluster) SnapshotSaveWithYAML ¶ added in v0.2.0
SnapshotSaveWithYAML save the snapshot of cluster
func (*Cluster) StartComponent ¶ added in v0.1.0
StartComponent starts a component in the cluster
func (*Cluster) StopComponent ¶ added in v0.1.0
StopComponent stops a component in the cluster