proxy

package
v0.5.8 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClusterProxyURL = "/apis/cluster.karpor.io/v1beta1/clusters/%s/proxy/"
)

Variables

This section is empty.

Functions

func ClusterFrom

func ClusterFrom(ctx context.Context) (string, bool)

ClusterFrom returns the value of the cluster key on the ctx.

func WithCluster

func WithCluster(parent context.Context, cluster string) context.Context

WithCluster returns a context that describes the nested cluster context.

func WithProxyByCluster

func WithProxyByCluster(handler http.Handler) http.Handler

WithProxyByCluster returns a new http.Handler that provides proxy functionality based on the cluster information in the context.

Types

This section is empty.

Jump to

Keyboard shortcuts

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