Documentation
¶
Index ¶
- func AddHealthRoutes(mux *http.ServeMux)
- func AddUIAuthRoutes(mux *http.ServeMux, token string)
- func AddVersionRoutes(mux *http.ServeMux, version, nodeInstanceID, tenancy string)
- func AuthenticateCredential(token, cred string) bool
- func Handler(mux *http.ServeMux, config *Config) http.Handler
- func IsLoopbackAddress(addr string) bool
- func LoadConfig[T any](cfg *T) error
- func New(ctx context.Context, mux *http.ServeMux, nodeInstanceID, tenancy string, ...) (func() error, error)
- func ProtectAPI(token, allowedOrigins string, next http.Handler) http.Handler
- func ProtectMutatingAPI(token string, next http.Handler) http.Handler
- func ProtectMutatingAPIWithAllowedOrigins(token, allowedOrigins string, next http.Handler) http.Handler
- func ValidateLocalServeSecurity(addr, token string) error
- type Config
- type Dependencies
- type HealthResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddHealthRoutes ¶
func AddUIAuthRoutes ¶ added in v0.36.0
func AddVersionRoutes ¶
func AuthenticateCredential ¶ added in v0.36.0
func IsLoopbackAddress ¶
func LoadConfig ¶
func ProtectAPI ¶ added in v0.36.0
func ProtectMutatingAPIWithAllowedOrigins ¶ added in v0.33.0
Types ¶
type Config ¶
type Config struct {
Addr string `json:"addr"`
Port string `json:"port"`
Token string `json:"token"`
UIBaseURL string `json:"ui_base_url"`
AllowedAPIOrigins string `json:"allowed_api_origins"`
ProxyOrigin string `json:"proxy_origin"`
HarnessDevProxyURL string `json:"harness_dev_proxy_url"`
TerminalEnabled string `json:"terminal_enabled"`
TerminalAllowedRoot string `json:"terminal_allowed_root"`
TerminalShell string `json:"terminal_shell"`
TerminalIdleTimeout string `json:"terminal_idle_timeout"`
TerminalMaxSessions string `json:"terminal_max_sessions"`
WorkspaceRoots string `json:"workspace_roots"`
HITLApprovalTimeout string `json:"hitl_approval_timeout"`
TurnMax string `json:"contenox_turn_max"`
TurnGrace string `json:"contenox_turn_grace"`
SandboxShellScrub string `json:"sandbox_shell_scrub"`
SandboxTerminalScrub string `json:"sandbox_terminal_scrub"`
SandboxEnvAllow string `json:"sandbox_env_allow"`
SandboxEnvDeny string `json:"sandbox_env_deny"`
}
type Dependencies ¶
type Dependencies struct {
DB libdb.DBManager
PubSub libbus.Messenger
State *runtimestate.State
ToolsProviderService toolsproviderservice.Service
Auth middleware.AuthZReader
Agent agentservice.Agent
Chains taskchainservice.Service
Fleet fleetservice.Service
Missions missionservice.Service
MissionChanges missionchanges.Service
OperatorInbox operatorinbox.Service
HITL hitlservice.Service
Tracker libtracker.ActivityTracker
WorkspaceID string
ProjectRoot string
ContenoxDir string
WorkspaceRoots *vfs.Factory
WorkspaceRootMutators *localfileapi.RootsMutators
Defaults stateservice.RuntimeDefaults
TerminalService terminalservice.Service
TerminalEnabled bool
HITLPolicySource hitlservice.PolicySource
HITLDefaultPolicyName string
AgentsConfigApplied func(ctx context.Context, scope, workspaceRoot string)
}
type HealthResponse ¶
type HealthResponse struct {
Status string `json:"status"`
}
Click to show internal directories.
Click to hide internal directories.