k8s

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2026 License: GPL-3.0 Imports: 20 Imported by: 0

Documentation

Overview

Package k8s 实现 k8s binder:集群/命名空间资源、Pod 详情与日志流。

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type K8s

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

K8s binder。

func New

func New(appCtx context.Context, lang LangProvider, pool *sshpool.Pool) *K8s

New 构造 k8s binder。

func (*K8s) Cleanup

func (k *K8s) Cleanup()

Cleanup 取消所有正在跑的 pod log 流。

func (*K8s) GetK8sClusterInfo

func (k *K8s) GetK8sClusterInfo(assetID int64) (string, error)

func (*K8s) GetK8sNamespaceConfigMaps

func (k *K8s) GetK8sNamespaceConfigMaps(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sNamespaceDeployments

func (k *K8s) GetK8sNamespaceDeployments(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sNamespacePods

func (k *K8s) GetK8sNamespacePods(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sNamespaceResources

func (k *K8s) GetK8sNamespaceResources(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sNamespaceSecrets

func (k *K8s) GetK8sNamespaceSecrets(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sNamespaceServices

func (k *K8s) GetK8sNamespaceServices(assetID int64, namespace string) (string, error)

func (*K8s) GetK8sPodDetail

func (k *K8s) GetK8sPodDetail(assetID int64, namespace, podName string) (string, error)

func (*K8s) StartK8sPodLogs

func (k *K8s) StartK8sPodLogs(assetID int64, namespace, podName, container string, tailLines int64) (string, error)

func (*K8s) Startup

func (k *K8s) Startup(ctx context.Context)

Startup 保存 Wails ctx。

func (*K8s) StopK8sPodLogs

func (k *K8s) StopK8sPodLogs(streamID string)

type LangProvider

type LangProvider interface {
	Lang() string
}

LangProvider 由 system binder 实现。

Jump to

Keyboard shortcuts

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