kubego

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

README

kubego

GoDoc

a simple wrapper around kubernetes-client-go(since it's annoying)

go get github.com/graphikDB/kubego

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is a kubernetes client

func NewInClusterClient

func NewInClusterClient() (*Client, error)

NewInClusterClient returns a client for use when inside the kubernetes cluster

func NewOutOfClusterClient

func NewOutOfClusterClient() (*Client, error)

NewOutOfClusterClient returns a client for use when not inside the kubernetes cluster

func (*Client) ConfigMaps

func (p *Client) ConfigMaps(namespace string) v12.ConfigMapInterface

ConfigMaps returns an interface for managing k8s config maps

func (*Client) CronJobs

func (p *Client) CronJobs(namespace string) v1beta1.CronJobInterface

CronJobs returns an interface for managing k8s cronjobs

func (*Client) DaemonSets

func (p *Client) DaemonSets(namespace string) v1.DaemonSetInterface

DaemonSets returns an interface for managing k8s daemonsets

func (*Client) Deployments

func (p *Client) Deployments(namespace string) v1.DeploymentInterface

Deployments returns an interface for managing k8s deployments

func (*Client) Do added in v0.0.3

func (c *Client) Do(fn Func) error

Do executes the given function against the client

func (*Client) Endpoints

func (p *Client) Endpoints(namespace string) v12.EndpointsInterface

Endpoints returns an interface for managing k8s endpoints

func (*Client) Events

func (p *Client) Events(namespace string) v12.EventInterface

Events returns an interface for managing k8s events

func (*Client) GetLogs added in v0.0.3

func (p *Client) GetLogs(ctx context.Context, opts *LogOpts) (io.ReadCloser, error)

GetLogs returns a readerCloser that streams the pod's logs

func (*Client) Ingresses

func (p *Client) Ingresses(namespace string) v14.IngressInterface

Ingresses returns an interface for managing k8s ingresses

func (*Client) Jobs

func (p *Client) Jobs(namespace string) v13.JobInterface

Jobs returns an interface for managing k8s jobs

func (*Client) Namespaces

func (p *Client) Namespaces() v12.NamespaceInterface

Namespaces returns an interface for managing k8s namespaces

func (*Client) Nodes

func (p *Client) Nodes() v12.NodeInterface

Nodes returns an interface for managing k8s nodes

func (*Client) PersistentVolumeClaims

func (p *Client) PersistentVolumeClaims(namespace string) v12.PersistentVolumeClaimInterface

PersistentVolumeClaims returns an interface for managing k8s persistant volume claims

func (*Client) PersistentVolumes

func (p *Client) PersistentVolumes() v12.PersistentVolumeInterface

PersistentVolumes returns an interface for managing k8s persistant volumes

func (*Client) Pods

func (p *Client) Pods(namespace string) v12.PodInterface

Pods returns an interface for managing k8s pods

func (*Client) ReplicaSets

func (p *Client) ReplicaSets(namespace string) v1.ReplicaSetInterface

ReplicaSets returns an interface for managing k8s replicasets

func (*Client) ResourceQuotas

func (p *Client) ResourceQuotas(namespace string) v12.ResourceQuotaInterface

ResourceQuotas returns an interface for managing k8s resource quotas

func (*Client) Secrets

func (p *Client) Secrets(namespace string) v12.SecretInterface

Secrets returns an interface for managing k8s secrets

func (*Client) ServiceAccounts

func (p *Client) ServiceAccounts(namespace string) v12.ServiceAccountInterface

ServiceAccounts returns an interface for managing k8s service accounts

func (*Client) Services

func (p *Client) Services(namespace string) v12.ServiceInterface

Services returns an interface for managing k8s services

func (*Client) StatefulSets

func (p *Client) StatefulSets(namespace string) v1.StatefulSetInterface

StatefulSets returns an interface for managing k8s statefulsets

type Func added in v0.0.3

type Func func(c *Client) error

Func is a function that executes against a Client

type LogOpts added in v0.0.3

type LogOpts struct {
	Watch     bool
	Previous  bool
	PodID     string
	Container string
	Namespace string
	Tail      int64
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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