Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthConfig ¶ added in v0.7.0
type AuthConfig struct {
Type string // "serviceaccount", "bearer", "basic", "none"
Token string
Username string
Password string
}
AuthConfig represents authentication configuration for a route
type Config ¶
type Config struct {
ServerURL string
PlaneType string // "dataplane" or "buildplane"
PlaneName string
ClientCertPath string
ClientKeyPath string
ServerCAPath string
ReconnectDelay time.Duration
HeartbeatInterval time.Duration
RequestTimeout time.Duration
Routes []RouteConfig // Backend service routes for HTTP proxy
}
type Route ¶ added in v0.7.0
type Route struct {
Name string
Backend string // "kubernetes", "http", "https"
Endpoint string
Auth AuthConfig
Transport http.RoundTripper
}
Route represents a configured backend service route. This is used to route requests to different backend services.
type RouteConfig ¶ added in v0.7.0
type RouteConfig struct {
Name string
Endpoint string
Auth AuthConfig
}
RouteConfig represents the configuration for a backend route
type Router ¶ added in v0.7.0
type Router struct {
// contains filtered or unexported fields
}
Router routes HTTP tunnel requests to different backend services
func NewRouter ¶ added in v0.7.0
func NewRouter(k8sConfig *rest.Config, routeConfigs []RouteConfig, logger *slog.Logger) (*Router, error)
NewRouter creates a new router with configured routes
func (*Router) Route ¶ added in v0.7.0
func (r *Router) Route(req *messaging.HTTPTunnelRequest) *messaging.HTTPTunnelResponse
Route routes an HTTP tunnel request to the appropriate backend service
Click to show internal directories.
Click to hide internal directories.