subresourceserver

package module
v0.0.0-...-2a43890 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2022 License: Apache-2.0 Imports: 26 Imported by: 2

README

Kubernetes subresource-server-runtime Project

build PRs Welcome

⚠️ DEPRECATED: CONSIDER USING apiserver-runtime INSTEAD.

The Kubernetes subresource-server-runtime project is a Go library for building subresource servers. Check out the example to get more details and usage.

License

This project is licensed under the Apache-2.0 License. See the LICENSE file for more information.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

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

func New

func New(client kubernetes.Interface, opts ...ServerOption) *Server

func (*Server) AddSubresource

func (s *Server) AddSubresource(r *Subresource)

func (*Server) Start

func (s *Server) Start(ctx context.Context) error

type ServerOption

type ServerOption interface {
	// contains filtered or unexported methods
}

func WithAddr

func WithAddr(addr string) ServerOption

func WithCertDir

func WithCertDir(certDir string) ServerOption

func WithCertFileName

func WithCertFileName(certFileName string) ServerOption

func WithKeyFileName

func WithKeyFileName(keyFileName string) ServerOption

type Subresource

type Subresource struct {
	NamespaceScoped      bool
	GroupVersionResource schema.GroupVersionResource
	Name                 string
	ConnectMethods       []string
	Connect              func(ctx context.Context, key types.NamespacedName) (http.Handler, error)
	Route                func(ctx context.Context, key types.NamespacedName, path string) (http.Handler, error)
}

func (*Subresource) Path

func (r *Subresource) Path(key types.NamespacedName) string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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