Documentation
¶
Index ¶
- func AuditDetails(m map[string]any) string
- type LoginRequest
- type MFARequest
- type PinKeyRequest
- type RemotePairRequest
- type ScheduleRequest
- type Server
- func (s *Server) ApplyInstaller(ctx context.Context, raw []byte, check bool) (applysetup.Report, error)
- func (s *Server) BeginShutdown()
- func (s *Server) Connected(endpointID string) bool
- func (s *Server) RunLocalDocker(ctx context.Context) error
- func (s *Server) RunPolicies(ctx context.Context, done chan<- struct{})
- func (s *Server) RunServiceReadSummaries(ctx context.Context, done chan<- struct{})
- func (s *Server) RunValidations(ctx context.Context, done chan<- struct{})
- func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)
- func (s *Server) WaitDetached()
- type ThemeUpdateRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AuditDetails ¶
AuditDetails flattens the lib's details map into the bounded audit column. Locally derived fields go first so a long remote error cannot displace the useful facts.
Types ¶
type LoginRequest ¶
type MFARequest ¶
type PinKeyRequest ¶
type RemotePairRequest ¶
type ScheduleRequest ¶
type ScheduleRequest struct {
IntervalSec int64 `json:"interval_sec"`
}
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) ApplyInstaller ¶
func (s *Server) ApplyInstaller(ctx context.Context, raw []byte, check bool) (applysetup.Report, error)
Native provider readers consume this immutable record immediately; no restart or second database writer is needed to activate the configuration.
func (*Server) BeginShutdown ¶
func (s *Server) BeginShutdown()
BeginShutdown makes readiness fail before the listener drains.
func (*Server) Connected ¶
Connected reports whether an endpoint holds a live socket; tests and status screens use it.
func (*Server) RunLocalDocker ¶
RunLocalDocker runs the existing authenticated agent against the local socket, inside the server process. No enrollment token, separate container or shell command is needed. Tenant authorization still gates every operator request.
func (*Server) RunPolicies ¶
RunPolicies runs the update-policy scheduler until ctx ends: a tick a minute, each run in its own goroutine. done closes only once no run is in flight, so runServer can wait on it before the store closes.
func (*Server) RunServiceReadSummaries ¶
RunServiceReadSummaries writes one service_token.reads row per token per hour and once more at shutdown, on a context detached from the loop so the last flush lands. It closes done only when it returns; runServer waits on it before the store closes.
func (*Server) RunValidations ¶
RunValidations watches every settled apply until ctx ends (docs/application-schema.md, Health validation). A tick runs to its end, a rollback included, so done closes only between ticks and runServer can wait on it before the store closes.
func (*Server) WaitDetached ¶
func (s *Server) WaitDetached()
WaitDetached blocks until every request that detached from its connection has finished. It is called after http.Server.Shutdown and before the store is closed: pairing, the key pin and a deposit all keep writing after their connection is gone, and a closed store under them leaves a key pinned on disk with no row recording it.
type ThemeUpdateRequest ¶
type ThemeUpdateRequest struct {
Theme string `json:"theme"`
}
Source Files
¶
- account_handlers.go
- admin_handlers.go
- agent_connect.go
- application_handlers.go
- auth_handlers.go
- backup_handlers.go
- configuration_handlers.go
- container_update_handlers.go
- endpoint_handlers.go
- exec_handlers.go
- exec_streams.go
- health.go
- image_check_handlers.go
- inspection.go
- installer.go
- installer_directory.go
- local_docker.go
- log_handlers.go
- log_streams.go
- migration_handlers.go
- password_handlers.go
- plan_inspection.go
- policies.go
- policy_handlers.go
- provider_handlers.go
- recreate_handlers.go
- registry_handlers.go
- run_yaml_handlers.go
- runtime_gate.go
- server.go
- service_reads.go
- service_token_handlers.go
- settings_handlers.go
- sso_handlers.go
- tenant_handlers.go
- validations.go
- workload_handlers.go
- workload_images.go
- workload_update_handlers.go