Documentation
¶
Index ¶
- Constants
- func DefaultDBPath() string
- type GuestOS
- type IsolatedVM
- type NATAllocation
- type NATState
- type NetworkLifecycleState
- type Orchestrator
- type OrchestratorLifecycleState
- type PrivateNetwork
- type RelayAllocation
- type RelayLifecycleState
- type Store
- func (s *Store) Close() error
- func (s *Store) CountActiveVMs(ctx context.Context, networkID string) (int, error)
- func (s *Store) GetNAT(ctx context.Context, vmID string) (NATAllocation, error)
- func (s *Store) GetNetwork(ctx context.Context, id string) (PrivateNetwork, error)
- func (s *Store) GetOrchestrator(ctx context.Context, id string) (Orchestrator, error)
- func (s *Store) GetRelay(ctx context.Context, id string) (RelayAllocation, error)
- func (s *Store) GetRelayForVM(ctx context.Context, id string) (RelayAllocation, error)
- func (s *Store) GetVM(ctx context.Context, id string) (IsolatedVM, error)
- func (s *Store) ListNAT(ctx context.Context, orchestratorID, networkID, state string) ([]NATAllocation, error)
- func (s *Store) ListNetworks(ctx context.Context, orchestratorID string) ([]PrivateNetwork, error)
- func (s *Store) ListOrchestrators(ctx context.Context, host string) ([]Orchestrator, error)
- func (s *Store) ListRelays(ctx context.Context, orchestratorID, vmID string) ([]RelayAllocation, error)
- func (s *Store) ListVMs(ctx context.Context, orchestratorID, networkID string) ([]IsolatedVM, error)
- func (s *Store) Path() string
- func (s *Store) PutNAT(ctx context.Context, v NATAllocation) error
- func (s *Store) PutNetwork(ctx context.Context, v PrivateNetwork) error
- func (s *Store) PutOrchestrator(ctx context.Context, v Orchestrator) error
- func (s *Store) PutRelay(ctx context.Context, v RelayAllocation) error
- func (s *Store) PutVM(ctx context.Context, v IsolatedVM) error
- func (s *Store) QueryContext(ctx context.Context, query string, args ...any) (*sql.Rows, error)
- func (s *Store) SchemaVersion(ctx context.Context) (int, error)
- type UnixSeconds
- type VMLifecycleState
Constants ¶
View Source
const CurrentSchemaVersion = 1
Variables ¶
This section is empty.
Functions ¶
func DefaultDBPath ¶
func DefaultDBPath() string
Types ¶
type IsolatedVM ¶
type IsolatedVM struct {
ID string
OrchestratorID string
NetworkID string
DisplayName string
HyperVName string
HyperVVMID *string
HyperVAdapterID *string
NodeName string
GuestOS GuestOS
ProfileName string
IPv4 string
MAC string
PrefixLength int
GatewayIPv4 string
DNSServersJSON string
StorageRoot string
VMPath string
VHDPath string
LifecycleState VMLifecycleState
CreatedAt UnixSeconds
UpdatedAt UnixSeconds
RetiredAt *UnixSeconds
}
type NATAllocation ¶
type NATAllocation struct {
VMID string
OrchestratorID string
State NATState
ConntrackMark int64
UpdatedAt UnixSeconds
}
type NetworkLifecycleState ¶
type NetworkLifecycleState string
const ( NetworkCreating NetworkLifecycleState = "creating" NetworkReady NetworkLifecycleState = "ready" NetworkDegraded NetworkLifecycleState = "degraded" NetworkDeleting NetworkLifecycleState = "deleting" NetworkDeleted NetworkLifecycleState = "deleted" )
type Orchestrator ¶
type Orchestrator struct {
ID string
DisplayName string
PhysicalHostID string
HostNode string
HyperVName string
HyperVVMID *string
NodeName string
ProfileName string
MainVSwitch string
MainMAC *string
MainIP *string
AgentPort int
ApplianceSchema int
LifecycleState OrchestratorLifecycleState
HealthState string
MaxNetworks int
MaxVMs int
CreatedAt UnixSeconds
UpdatedAt UnixSeconds
LastSeenAt *UnixSeconds
}
type OrchestratorLifecycleState ¶
type OrchestratorLifecycleState string
const ( OrchestratorCreating OrchestratorLifecycleState = "creating" OrchestratorReady OrchestratorLifecycleState = "ready" OrchestratorDegraded OrchestratorLifecycleState = "degraded" OrchestratorDeleting OrchestratorLifecycleState = "deleting" OrchestratorDeleted OrchestratorLifecycleState = "deleted" )
type PrivateNetwork ¶
type PrivateNetwork struct {
ID string
OrchestratorID string
DisplayName string
HyperVSwitchName string
HyperVSwitchGUID *string
OrchestratorAdapterID *string
SubnetIndex int
CIDR string
GatewayIPv4 string
OrchestratorMAC string
DNSServersJSON string
LifecycleState NetworkLifecycleState
CreatedAt UnixSeconds
UpdatedAt UnixSeconds
RetiredAt *UnixSeconds
}
type RelayAllocation ¶
type RelayAllocation struct {
ID string
VMID string
OrchestratorID string
ListenPort int
TargetIPv4 string
TargetPort int
LifecycleState RelayLifecycleState
CreatedAt UnixSeconds
UpdatedAt UnixSeconds
RetiredAt *UnixSeconds
}
type RelayLifecycleState ¶
type RelayLifecycleState string
const ( RelayReady RelayLifecycleState = "ready" RelayDegraded RelayLifecycleState = "degraded" RelayRemoving RelayLifecycleState = "removing" RelayRemoved RelayLifecycleState = "removed" )
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func (*Store) CountActiveVMs ¶
func (*Store) GetNetwork ¶
func (*Store) GetOrchestrator ¶
func (*Store) GetRelayForVM ¶
func (*Store) ListNetworks ¶
func (*Store) ListOrchestrators ¶
func (*Store) ListRelays ¶
func (*Store) PutNetwork ¶
func (s *Store) PutNetwork(ctx context.Context, v PrivateNetwork) error
func (*Store) PutOrchestrator ¶
func (s *Store) PutOrchestrator(ctx context.Context, v Orchestrator) error
func (*Store) QueryContext ¶
type UnixSeconds ¶
type UnixSeconds int64
type VMLifecycleState ¶
type VMLifecycleState string
const ( VMCreating VMLifecycleState = "creating" VMProvisioning VMLifecycleState = "provisioning" VMReady VMLifecycleState = "ready" VMDegraded VMLifecycleState = "degraded" VMDeleting VMLifecycleState = "deleting" VMDeleted VMLifecycleState = "deleted" )
Click to show internal directories.
Click to hide internal directories.