env

package
v0.0.0-...-cda7753 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2022 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConfigMapGVR = v1.SchemeGroupVersion.WithResource("configmaps")
View Source
var PodGVR = v1.SchemeGroupVersion.WithResource("pods")
View Source
var ServiceGVR = v1.SchemeGroupVersion.WithResource("services")

Functions

This section is empty.

Types

type Client

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

func NewClient

func NewClient(ctx context.Context, clientset *kubernetes.Clientset, namespace string, slackWebhook string) *Client

func (*Client) DeleteEnv

func (c *Client) DeleteEnv(ctx context.Context, name string) error

Delete the configuration for the env.

func (*Client) GetEnv

func (c *Client) GetEnv(ctx context.Context, name string) (*Env, error)

Fetch all the objects associated with this env.

The API currently assumes every user has exactly one env. Returns (nil, nil) if the env does not exist.

func (*Client) SetEnvSpec

func (c *Client) SetEnvSpec(ctx context.Context, name string, spec ephconfig.EnvSpec) error

Set the configuration for the env.

type Env

type Env struct {
	ConfigMap *v1.ConfigMap
	Pod       *v1.Pod
	Service   *v1.Service
	PodLogs   *bytes.Buffer
}

func (*Env) PodLogsWithoutColor

func (e *Env) PodLogsWithoutColor() string

Jump to

Keyboard shortcuts

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