Documentation ¶
Index ¶
- func ServerResourceForGroupVersionKind(discoveryClient discovery.DiscoveryInterface, gvk schema.GroupVersionKind) (*metav1.APIResource, error)
- type EventsResponse
- type K8sClientService
- type K8sClientServiceImpl
- func (impl K8sClientServiceImpl) CreateResource(restConfig *rest.Config, request *K8sRequestBean, manifest string) (*ManifestResponse, error)
- func (impl K8sClientServiceImpl) DeleteResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
- func (impl K8sClientServiceImpl) GetPodLogs(restConfig *rest.Config, request *K8sRequestBean) (io.ReadCloser, error)
- func (impl K8sClientServiceImpl) GetResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
- func (impl K8sClientServiceImpl) GetResourceIf(restConfig *rest.Config, request *K8sRequestBean) (resourceIf dynamic.NamespaceableResourceInterface, namespaced bool, err error)
- func (impl K8sClientServiceImpl) ListEvents(restConfig *rest.Config, request *K8sRequestBean) (*EventsResponse, error)
- func (impl K8sClientServiceImpl) UpdateResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
- type K8sRequestBean
- type ManifestResponse
- type PodLogsRequest
- type ResourceIdentifier
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ServerResourceForGroupVersionKind ¶
func ServerResourceForGroupVersionKind(discoveryClient discovery.DiscoveryInterface, gvk schema.GroupVersionKind) (*metav1.APIResource, error)
Types ¶
type EventsResponse ¶
type K8sClientService ¶
type K8sClientService interface { GetResource(restConfig *rest.Config, request *K8sRequestBean) (resp *ManifestResponse, err error) CreateResource(restConfig *rest.Config, request *K8sRequestBean, manifest string) (resp *ManifestResponse, err error) UpdateResource(restConfig *rest.Config, request *K8sRequestBean) (resp *ManifestResponse, err error) DeleteResource(restConfig *rest.Config, request *K8sRequestBean) (resp *ManifestResponse, err error) ListEvents(restConfig *rest.Config, request *K8sRequestBean) (*EventsResponse, error) GetPodLogs(restConfig *rest.Config, request *K8sRequestBean) (io.ReadCloser, error) }
type K8sClientServiceImpl ¶
type K8sClientServiceImpl struct {
// contains filtered or unexported fields
}
func NewK8sClientServiceImpl ¶
func NewK8sClientServiceImpl(logger *zap.SugaredLogger, clusterRepository repository.ClusterRepository) *K8sClientServiceImpl
func (K8sClientServiceImpl) CreateResource ¶
func (impl K8sClientServiceImpl) CreateResource(restConfig *rest.Config, request *K8sRequestBean, manifest string) (*ManifestResponse, error)
func (K8sClientServiceImpl) DeleteResource ¶
func (impl K8sClientServiceImpl) DeleteResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
func (K8sClientServiceImpl) GetPodLogs ¶
func (impl K8sClientServiceImpl) GetPodLogs(restConfig *rest.Config, request *K8sRequestBean) (io.ReadCloser, error)
func (K8sClientServiceImpl) GetResource ¶
func (impl K8sClientServiceImpl) GetResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
func (K8sClientServiceImpl) GetResourceIf ¶
func (impl K8sClientServiceImpl) GetResourceIf(restConfig *rest.Config, request *K8sRequestBean) (resourceIf dynamic.NamespaceableResourceInterface, namespaced bool, err error)
func (K8sClientServiceImpl) ListEvents ¶
func (impl K8sClientServiceImpl) ListEvents(restConfig *rest.Config, request *K8sRequestBean) (*EventsResponse, error)
func (K8sClientServiceImpl) UpdateResource ¶
func (impl K8sClientServiceImpl) UpdateResource(restConfig *rest.Config, request *K8sRequestBean) (*ManifestResponse, error)
type K8sRequestBean ¶
type K8sRequestBean struct { ResourceIdentifier ResourceIdentifier `json:"resourceIdentifier"` Patch string `json:"patch,omitempty"` PodLogsRequest PodLogsRequest `json:"podLogsRequest,omitempty"` }
type ManifestResponse ¶
type ManifestResponse struct {
Manifest unstructured.Unstructured `json:"manifest,omitempty"`
}
type PodLogsRequest ¶
type ResourceIdentifier ¶
type ResourceIdentifier struct { Name string `json:"name"` //pod name for logs request Namespace string `json:"namespace"` GroupVersionKind schema.GroupVersionKind `json:"groupVersionKind"` }
Click to show internal directories.
Click to hide internal directories.