Documentation
¶
Index ¶
- type ChangePortRequest
- type ClientConfig
- type ComposeAppStoreInfo
- type ComposeAppWithStoreInfo
- type DeviceInfo
- type HotspotConfig
- type IPv4Config
- type NetworkInterface
- type NetworkZone
- type Result
- type Route
- type SSLConfigRequest
- type SSLConfigResponse
- type UnifiedInterfaceConfig
- type WirelessConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChangePortRequest ¶
type ChangePortRequest struct {
Port string `json:"port" binding:"required"`
}
type ClientConfig ¶
type ClientConfig struct {
SSID string `json:"ssid,omitempty"`
Password string `json:"password,omitempty"`
}
ClientConfig is the unified client config for a single interface (stored in network-config.json)
type ComposeAppStoreInfo ¶
type ComposeAppStoreInfo struct {
Architectures []string `json:"architectures,omitempty" yaml:",omitempty"`
Author string `json:"author"`
Category string `json:"category"`
Description map[string]string `json:"description"`
Developer string `json:"developer"`
Hostname string `json:"hostname,omitempty" yaml:",omitempty"`
Icon string `json:"icon"`
Index string `json:"index" yaml:",omitempty"`
Main string `json:"main,omitempty" yaml:",omitempty"`
PortMap string `json:"port_map" mapstructure:"port_map" yaml:"port_map,omitempty"`
Scheme string `json:"scheme,omitempty" yaml:",omitempty"`
ScreenshotLink []string `json:"screenshot_link" mapstructure:"screenshot_link" yaml:"screenshot_link,omitempty"`
StoreAppID string `json:"store_app_id,omitempty" mapstructure:"store_app_id" yaml:"store_app_id,omitempty"`
Tagline map[string]string `json:"tagline"`
Thumbnail string `json:"thumbnail"`
Title map[string]string `json:"title"`
}
type ComposeAppWithStoreInfo ¶
type ComposeAppWithStoreInfo struct {
// Compose See [Compose Specification](https://compose-spec.io) for the schema structure of `ComposeApp`.
Status string `json:"status,omitempty"`
StoreInfo ComposeAppStoreInfo `json:"store_info,omitempty"`
UpdateAvailable bool `json:"update_available,omitempty" yaml:",omitempty"`
}
type DeviceInfo ¶
type DeviceInfo struct {
LanIpv4 []string `json:"lan_ipv4"`
Port int `json:"port"`
DeviceName string `json:"device_name"`
DeviceModel string `json:"device_model"`
Initialized bool `json:"initialized"`
OS_Version string `json:"os_version"`
Hash string `json:"hash"`
RequestIp string `json:"request_ip,omitempty"`
TB_Ipv4 []string `json:"tb_ipv4"`
Ip4 []map[string]string `json:"ip4"`
}
type HotspotConfig ¶
type HotspotConfig struct {
SSID string `json:"ssid"`
Password string `json:"password,omitempty"`
Channel int `json:"channel,omitempty"`
}
HotspotConfig is the unified AP config for a single interface (stored in network-config.json)
type IPv4Config ¶
type NetworkInterface ¶
type NetworkInterface struct {
Name string `json:"name"`
Type string `json:"type"` // "ethernet", "bridge", "wifi", "thunderbolt"
IsVirtual bool `json:"is_virtual"` // true for br-*, docker0, etc.
MAC string `json:"mac"`
Speed string `json:"speed,omitempty"` // e.g. "1000", "20000"
State string `json:"state"` // "up", "down"
IPv4 *IPv4Config `json:"ipv4,omitempty"`
Wireless *WirelessConfig `json:"wireless,omitempty"`
Zone string `json:"zone,omitempty"` // "lan", "wan", or ""
Ports []string `json:"ports,omitempty"` // for bridges, which ports are attached
HybridCapable bool `json:"hybridCapable,omitempty"` // WiFi card supports client+AP simultaneously
}
NetworkInterface represents a single network interface configuration. Type is auto-detected from sysfs: "ethernet", "wifi", "bridge", "thunderbolt".
type NetworkZone ¶
type SSLConfigRequest ¶
type SSLConfigResponse ¶
type UnifiedInterfaceConfig ¶
type UnifiedInterfaceConfig struct {
Mode string `json:"mode"` // "client", "ap", "concurrent"
Zone string `json:"zone,omitempty"` // "lan", "wan", ""
Client *ClientConfig `json:"client,omitempty"`
Hotspot *HotspotConfig `json:"hotspot,omitempty"`
IPv4 *IPv4Config `json:"ipv4,omitempty"`
}
UnifiedInterfaceConfig is the single-source-of-truth for a network interface. One JSON file replaces the 3-4 separate config files.
type WirelessConfig ¶
type WirelessConfig struct {
Mode string `json:"mode"` // "client", "ap", "concurrent"
SSID string `json:"ssid,omitempty"`
ApSsid string `json:"apSsid,omitempty"`
Password string `json:"password,omitempty"` // client password (wpa-psk)
ApPassword string `json:"apPassword,omitempty"` // AP/hotspot password
Channel int `json:"channel,omitempty"`
HybridMode bool `json:"hybridMode,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.