computer-host/contract/networking.go

21 lines
424 B
Go

package host
type MachinePortName string
type PortProtocol string
const (
MachinePortNameSSH MachinePortName = "ssh"
MachinePortNameVNC MachinePortName = "vnc"
)
const (
PortProtocolTCP PortProtocol = "tcp"
)
type MachinePort struct {
Name MachinePortName `json:"name"`
Port uint16 `json:"port"`
HostPort uint16 `json:"host_port,omitempty"`
Protocol PortProtocol `json:"protocol"`
}