Documentation
¶
Index ¶
- Constants
- Variables
- type Endpoint
- type Endpoints
- func (o *Endpoints) Decode(e entity.AttrGetter)
- func (o *Endpoints) Empty() bool
- func (o *Endpoints) Encode() (attrs []entity.Attr)
- func (o *Endpoints) EntityId() entity.Id
- func (o *Endpoints) InitSchema(sb *schema.SchemaBuilder)
- func (o *Endpoints) Is(e entity.AttrGetter) bool
- func (o *Endpoints) Kind() entity.Id
- func (o *Endpoints) ShortKind() string
- type Port
- type PortProtocol
- type Service
- func (o *Service) Decode(e entity.AttrGetter)
- func (o *Service) Empty() bool
- func (o *Service) Encode() (attrs []entity.Attr)
- func (o *Service) EntityId() entity.Id
- func (o *Service) InitSchema(sb *schema.SchemaBuilder)
- func (o *Service) Is(e entity.AttrGetter) bool
- func (o *Service) Kind() entity.Id
- func (o *Service) ShortKind() string
Constants ¶
View Source
const ( EndpointsEndpointId = entity.Id("dev.miren.network/endpoints.endpoint") EndpointsServiceId = entity.Id("dev.miren.network/endpoints.service") )
View Source
const ( EndpointIpId = entity.Id("dev.miren.network/endpoint.ip") EndpointPortId = entity.Id("dev.miren.network/endpoint.port") )
View Source
const ( ServiceIpId = entity.Id("dev.miren.network/service.ip") ServiceMatchId = entity.Id("dev.miren.network/service.match") ServicePortId = entity.Id("dev.miren.network/service.port") )
View Source
const ( PortNameId = entity.Id("dev.miren.network/port.name") PortNodePortId = entity.Id("dev.miren.network/port.node_port") PortPortId = entity.Id("dev.miren.network/port.port") PortProtocolId = entity.Id("dev.miren.network/port.protocol") PortProtocolTcpId = entity.Id("dev.miren.network/protocol.tcp") PortProtocolUdpId = entity.Id("dev.miren.network/protocol.udp") PortTargetPortId = entity.Id("dev.miren.network/port.target_port") PortTypeId = entity.Id("dev.miren.network/port.type") )
Variables ¶
View Source
var ( KindEndpoints = entity.Id("dev.miren.network/kind.endpoints") KindService = entity.Id("dev.miren.network/kind.service") Schema = entity.Id("dev.miren.network/schema.v1alpha") )
View Source
var PortprotocolFromId = map[entity.Id]PortProtocol{PortProtocolTcpId: TCP, PortProtocolUdpId: UDP}
View Source
var PortprotocolToId = map[PortProtocol]entity.Id{TCP: PortProtocolTcpId, UDP: PortProtocolUdpId}
Functions ¶
This section is empty.
Types ¶
type Endpoint ¶
type Endpoint struct {
Ip string `cbor:"ip,omitempty" json:"ip,omitempty"`
Port int64 `cbor:"port,omitempty" json:"port,omitempty"`
}
func (*Endpoint) Decode ¶
func (o *Endpoint) Decode(e entity.AttrGetter)
func (*Endpoint) InitSchema ¶
func (o *Endpoint) InitSchema(sb *schema.SchemaBuilder)
type Endpoints ¶
type Endpoints struct {
ID entity.Id `json:"id"`
Endpoint []Endpoint `cbor:"endpoint,omitempty" json:"endpoint,omitempty"`
Service entity.Id `cbor:"service,omitempty" json:"service,omitempty"`
}
func (*Endpoints) Decode ¶
func (o *Endpoints) Decode(e entity.AttrGetter)
func (*Endpoints) InitSchema ¶
func (o *Endpoints) InitSchema(sb *schema.SchemaBuilder)
type Port ¶
type Port struct {
Name string `cbor:"name" json:"name"`
NodePort int64 `cbor:"node_port,omitempty" json:"node_port,omitempty"`
Port int64 `cbor:"port" json:"port"`
Protocol PortProtocol `cbor:"protocol,omitempty" json:"protocol,omitempty"`
TargetPort int64 `cbor:"target_port,omitempty" json:"target_port,omitempty"`
Type string `cbor:"type,omitempty" json:"type,omitempty"`
}
func (*Port) Decode ¶
func (o *Port) Decode(e entity.AttrGetter)
func (*Port) InitSchema ¶
func (o *Port) InitSchema(sb *schema.SchemaBuilder)
type PortProtocol ¶
type PortProtocol string
const ( TCP PortProtocol = "protocol.tcp" UDP PortProtocol = "protocol.udp" )
type Service ¶
type Service struct {
ID entity.Id `json:"id"`
Ip []string `cbor:"ip,omitempty" json:"ip,omitempty"`
Match types.Labels `cbor:"match,omitempty" json:"match,omitempty"`
Port []Port `cbor:"port,omitempty" json:"port,omitempty"`
}
func (*Service) Decode ¶
func (o *Service) Decode(e entity.AttrGetter)
func (*Service) InitSchema ¶
func (o *Service) InitSchema(sb *schema.SchemaBuilder)
Click to show internal directories.
Click to hide internal directories.