Version: v0.6.0 Latest Latest

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

Go to latest
Published: Oct 11, 2021 License: MIT Imports: 16 Imported by: 1




View Source
const Route = "/resources"

Route is the route under which the plugin should be registered in our router for the rest api.


This section is empty.


func Register

func Register(clusters *clusters.Clusters, plugins *plugin.Plugins, config Config) chi.Router

Register returns a new router which can be used in the router for the kobs rest api.


type Config

type Config struct {
	Forbidden           []string                    `json:"forbidden"`
	WebSocket           WebSocket                   `json:"webSocket"`
	EphemeralContainers []corev1.EphemeralContainer `json:"ephemeralContainers"`

Config is the structure of the configuration for the resources plugin. It only contains one filed to forbid access to the provided resources.

type Resources

type Resources struct {
	Cluster   string                 `json:"cluster"`
	Namespace string                 `json:"namespace"`
	Resources map[string]interface{} `json:"resources"`

Resources is the structure for the getResources api call. It contains the cluster, namespace and the json representation of the retunred list object from the Kuberntes API.

type Router

type Router struct {
	// contains filtered or unexported fields

Router implements the router for the resources plugin, which can be registered in the router for our rest api.

type WebSocket added in v0.5.0

type WebSocket struct {
	Address         string `json:"address"`
	AllowAllOrigins bool   `json:"allowAllOrigins"`

WebSocket is the structure for the WebSocket configuration for terminal for Pods.

Source Files

Jump to

Keyboard shortcuts

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