Documentation
¶
Index ¶
- Variables
- func PortMap() map[int]string
- type ConfigEnsurer
- type Dependency
- type DependencyChecker
- type HealthCheckResult
- type ManagedProcess
- type PortChecker
- type ProcessManager
- func (pm *ProcessManager) HealthCheckWithRetry(ctx context.Context, nodes []ipfsNodeInfo, retries int, ...) bool
- func (pm *ProcessManager) IPFSHealthCheck(ctx context.Context, nodes []ipfsNodeInfo) HealthCheckResult
- func (pm *ProcessManager) LibP2PHealthCheck(ctx context.Context) HealthCheckResult
- func (pm *ProcessManager) RQLiteHealthCheck(ctx context.Context) HealthCheckResult
- func (pm *ProcessManager) StartAll(ctx context.Context) error
- func (pm *ProcessManager) Status(ctx context.Context)
- func (pm *ProcessManager) StopAll(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
var RequiredPorts = []int{
4001, 4002, 4003,
4501, 4502, 4503,
5001, 5002, 5003,
7001, 7002, 7003,
6001,
3320, 3322,
9050,
9094, 9104, 9114,
8080, 8081, 8082,
}
RequiredPorts defines all ports needed for dev environment
Functions ¶
Types ¶
type ConfigEnsurer ¶
type ConfigEnsurer struct {
// contains filtered or unexported fields
}
ConfigEnsurer handles all config file creation and validation
func NewConfigEnsurer ¶
func NewConfigEnsurer(debrosDir string) *ConfigEnsurer
NewConfigEnsurer creates a new config ensurer
func (*ConfigEnsurer) EnsureAll ¶
func (ce *ConfigEnsurer) EnsureAll() error
EnsureAll ensures all necessary config files and secrets exist
type Dependency ¶
type Dependency struct {
Name string
Command string
MinVersion string // Optional: if set, try to check version
InstallHint string
}
Dependency represents an external binary dependency
type DependencyChecker ¶
type DependencyChecker struct {
// contains filtered or unexported fields
}
DependencyChecker handles dependency validation
func NewDependencyChecker ¶
func NewDependencyChecker() *DependencyChecker
NewDependencyChecker creates a new dependency checker
func (*DependencyChecker) CheckAll ¶
func (dc *DependencyChecker) CheckAll() ([]string, error)
CheckAll performs all dependency checks and returns a report
type HealthCheckResult ¶
HealthCheckResult represents the result of a health check
type ManagedProcess ¶
ManagedProcess tracks a running process
type PortChecker ¶
type PortChecker struct {
// contains filtered or unexported fields
}
PortChecker validates that required ports are available
func NewPortChecker ¶
func NewPortChecker() *PortChecker
NewPortChecker creates a new port checker with required ports
func (*PortChecker) CheckAll ¶
func (pc *PortChecker) CheckAll() ([]int, error)
CheckAll verifies all required ports are available
type ProcessManager ¶
type ProcessManager struct {
// contains filtered or unexported fields
}
ProcessManager manages all dev environment processes
func NewProcessManager ¶
func NewProcessManager(debrosDir string, logWriter io.Writer) *ProcessManager
NewProcessManager creates a new process manager
func (*ProcessManager) HealthCheckWithRetry ¶
func (pm *ProcessManager) HealthCheckWithRetry(ctx context.Context, nodes []ipfsNodeInfo, retries int, retryInterval time.Duration, timeout time.Duration) bool
HealthCheckWithRetry performs a health check with retry logic
func (*ProcessManager) IPFSHealthCheck ¶
func (pm *ProcessManager) IPFSHealthCheck(ctx context.Context, nodes []ipfsNodeInfo) HealthCheckResult
IPFSHealthCheck verifies IPFS peer connectivity
func (*ProcessManager) LibP2PHealthCheck ¶
func (pm *ProcessManager) LibP2PHealthCheck(ctx context.Context) HealthCheckResult
LibP2PHealthCheck verifies that network nodes have peer connections
func (*ProcessManager) RQLiteHealthCheck ¶
func (pm *ProcessManager) RQLiteHealthCheck(ctx context.Context) HealthCheckResult
RQLiteHealthCheck verifies RQLite cluster formation
func (*ProcessManager) StartAll ¶
func (pm *ProcessManager) StartAll(ctx context.Context) error
StartAll starts all development services
func (*ProcessManager) Status ¶
func (pm *ProcessManager) Status(ctx context.Context)
Status reports the status of all services