Documentation ¶
Index ¶
- Constants
- Variables
- func Key(name string, namespace string) string
- func KeyPrefix() string
- func ParsePodFromKey(key string) (pod string, namespace string, err error)
- type ID
- type Pod
- func (*Pod) Descriptor() ([]byte, []int)
- func (m *Pod) GetAnnotations() map[string]string
- func (m *Pod) GetContainer() []*Pod_Container
- func (m *Pod) GetHostIpAddress() string
- func (m *Pod) GetIpAddress() string
- func (m *Pod) GetLabel() []*Pod_Label
- func (m *Pod) GetLabels() map[string]string
- func (m *Pod) GetName() string
- func (m *Pod) GetNamespace() string
- func (*Pod) ProtoMessage()
- func (m *Pod) Reset()
- func (m *Pod) String() string
- func (m *Pod) XXX_DiscardUnknown()
- func (m *Pod) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Pod) XXX_Merge(src proto.Message)
- func (m *Pod) XXX_Size() int
- func (m *Pod) XXX_Unmarshal(b []byte) error
- type Pod_Container
- func (*Pod_Container) Descriptor() ([]byte, []int)
- func (m *Pod_Container) GetName() string
- func (m *Pod_Container) GetPort() []*Pod_Container_Port
- func (*Pod_Container) ProtoMessage()
- func (m *Pod_Container) Reset()
- func (m *Pod_Container) String() string
- func (m *Pod_Container) XXX_DiscardUnknown()
- func (m *Pod_Container) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Pod_Container) XXX_Merge(src proto.Message)
- func (m *Pod_Container) XXX_Size() int
- func (m *Pod_Container) XXX_Unmarshal(b []byte) error
- type Pod_Container_Port
- func (*Pod_Container_Port) Descriptor() ([]byte, []int)
- func (m *Pod_Container_Port) GetContainerPort() int32
- func (m *Pod_Container_Port) GetHostIpAddress() string
- func (m *Pod_Container_Port) GetHostPort() int32
- func (m *Pod_Container_Port) GetName() string
- func (m *Pod_Container_Port) GetProtocol() Pod_Container_Port_Protocol
- func (*Pod_Container_Port) ProtoMessage()
- func (m *Pod_Container_Port) Reset()
- func (m *Pod_Container_Port) String() string
- func (m *Pod_Container_Port) XXX_DiscardUnknown()
- func (m *Pod_Container_Port) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Pod_Container_Port) XXX_Merge(src proto.Message)
- func (m *Pod_Container_Port) XXX_Size() int
- func (m *Pod_Container_Port) XXX_Unmarshal(b []byte) error
- type Pod_Container_Port_Protocol
- type Pod_Label
- func (*Pod_Label) Descriptor() ([]byte, []int)
- func (m *Pod_Label) GetKey() string
- func (m *Pod_Label) GetValue() string
- func (*Pod_Label) ProtoMessage()
- func (m *Pod_Label) Reset()
- func (m *Pod_Label) String() string
- func (m *Pod_Label) XXX_DiscardUnknown()
- func (m *Pod_Label) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Pod_Label) XXX_Merge(src proto.Message)
- func (m *Pod_Label) XXX_Size() int
- func (m *Pod_Label) XXX_Unmarshal(b []byte) error
Constants ¶
View Source
const (
// PodKeyword defines the keyword identifying Pod data.
PodKeyword = "pod"
)
Variables ¶
View Source
var Pod_Container_Port_Protocol_name = map[int32]string{
0: "TCP",
1: "UDP",
}
View Source
var Pod_Container_Port_Protocol_value = map[string]int32{
"TCP": 0,
"UDP": 1,
}
Functions ¶
Types ¶
type Pod ¶
type Pod struct { // Name of the pod unique within the namespace. // Cannot be updated. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Namespace the pod is inserted into. // An empty namespace is equivalent to the "default" namespace, but "default" // is the canonical representation. // Cannot be updated. Namespace string `protobuf:"bytes,2,opt,name=namespace,proto3" json:"namespace,omitempty"` // A list of labels attached to this pod. // Maintained for backward compatibility, deprecated in favor of labels. // +optional Label []*Pod_Label `protobuf:"bytes,3,rep,name=label,proto3" json:"label,omitempty"` // IP address allocated to the pod. Routable at least within the cluster. // Empty if not yet allocated. // +optional IpAddress string `protobuf:"bytes,4,opt,name=ip_address,json=ipAddress,proto3" json:"ip_address,omitempty"` // IP address of the host to which the pod is assigned. // Empty if not yet scheduled. // +optional HostIpAddress string `protobuf:"bytes,5,opt,name=host_ip_address,json=hostIpAddress,proto3" json:"host_ip_address,omitempty"` // List of containers belonging to the pod. // Containers cannot currently be added or removed. // There must be at least one container in a Pod. // Cannot be updated. Container []*Pod_Container `protobuf:"bytes,6,rep,name=container,proto3" json:"container,omitempty"` // annotations is an unstructured key value map stored with a resource that may be // set by external tools to store and retrieve arbitrary metadata. They are not // queryable and should be preserved when modifying objects. // More info: http://kubernetes.io/docs/user-guide/annotations // +optional Annotations map[string]string `` /* 163-byte string literal not displayed */ // Map of string keys and values that can be used to organize and categorize // (scope and select) objects. May match selectors of replication controllers // and services. // More info: http://kubernetes.io/docs/user-guide/labels // +optional Labels map[string]string `` /* 153-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts.
func (*Pod) Descriptor ¶
func (*Pod) GetAnnotations ¶
func (*Pod) GetContainer ¶
func (m *Pod) GetContainer() []*Pod_Container
func (*Pod) GetHostIpAddress ¶
func (*Pod) GetIpAddress ¶
func (*Pod) GetNamespace ¶
func (*Pod) ProtoMessage ¶
func (*Pod) ProtoMessage()
func (*Pod) XXX_DiscardUnknown ¶ added in v1.4.0
func (m *Pod) XXX_DiscardUnknown()
func (*Pod) XXX_Marshal ¶ added in v1.4.0
func (*Pod) XXX_Unmarshal ¶ added in v1.4.0
type Pod_Container ¶
type Pod_Container struct { // Name of the container. // Each container in a pod has a unique name. // Cannot be updated. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // List of ports to expose from the container. Exposing a port here gives // the system additional information about the network connections a // container uses, but it is primarily informational. Not specifying a port // here DOES NOT prevent that port from being exposed. Any port which is // listening on the default "0.0.0.0" address inside a container will be // accessible from the network. // Cannot be updated. // +optional Port []*Pod_Container_Port `protobuf:"bytes,2,rep,name=port,proto3" json:"port,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
A single application container run within a pod.
func (*Pod_Container) Descriptor ¶
func (*Pod_Container) Descriptor() ([]byte, []int)
func (*Pod_Container) GetName ¶
func (m *Pod_Container) GetName() string
func (*Pod_Container) GetPort ¶
func (m *Pod_Container) GetPort() []*Pod_Container_Port
func (*Pod_Container) ProtoMessage ¶
func (*Pod_Container) ProtoMessage()
func (*Pod_Container) Reset ¶
func (m *Pod_Container) Reset()
func (*Pod_Container) String ¶
func (m *Pod_Container) String() string
func (*Pod_Container) XXX_DiscardUnknown ¶ added in v1.4.0
func (m *Pod_Container) XXX_DiscardUnknown()
func (*Pod_Container) XXX_Marshal ¶ added in v1.4.0
func (m *Pod_Container) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*Pod_Container) XXX_Merge ¶ added in v1.4.0
func (m *Pod_Container) XXX_Merge(src proto.Message)
func (*Pod_Container) XXX_Size ¶ added in v1.4.0
func (m *Pod_Container) XXX_Size() int
func (*Pod_Container) XXX_Unmarshal ¶ added in v1.4.0
func (m *Pod_Container) XXX_Unmarshal(b []byte) error
type Pod_Container_Port ¶
type Pod_Container_Port struct { // An IANA_SVC_NAME formatted port name, unique within the pod. // The name can be referred to by services, policies, ... // +optional Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Port number to expose on the host. // The port number is in the range: 0 < x < 65536. // If pod is in the host network namespace, this must match container_port. // Most containers do not need this. // +optional HostPort int32 `protobuf:"varint,2,opt,name=host_port,json=hostPort,proto3" json:"host_port,omitempty"` // Port number to expose on the pod's IP address. // The port number is in the range: 0 < x < 65536. ContainerPort int32 `protobuf:"varint,3,opt,name=container_port,json=containerPort,proto3" json:"container_port,omitempty"` // Protocol for port. Must be UDP or TCP. // Defaults to "TCP". // +optional Protocol Pod_Container_Port_Protocol `protobuf:"varint,4,opt,name=protocol,proto3,enum=pod.Pod_Container_Port_Protocol" json:"protocol,omitempty"` // What host IP to bind the external port to. // +optional HostIpAddress string `protobuf:"bytes,5,opt,name=host_ip_address,json=hostIpAddress,proto3" json:"host_ip_address,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Port represents a network port in a single container.
func (*Pod_Container_Port) Descriptor ¶
func (*Pod_Container_Port) Descriptor() ([]byte, []int)
func (*Pod_Container_Port) GetContainerPort ¶
func (m *Pod_Container_Port) GetContainerPort() int32
func (*Pod_Container_Port) GetHostIpAddress ¶
func (m *Pod_Container_Port) GetHostIpAddress() string
func (*Pod_Container_Port) GetHostPort ¶
func (m *Pod_Container_Port) GetHostPort() int32
func (*Pod_Container_Port) GetName ¶
func (m *Pod_Container_Port) GetName() string
func (*Pod_Container_Port) GetProtocol ¶
func (m *Pod_Container_Port) GetProtocol() Pod_Container_Port_Protocol
func (*Pod_Container_Port) ProtoMessage ¶
func (*Pod_Container_Port) ProtoMessage()
func (*Pod_Container_Port) Reset ¶
func (m *Pod_Container_Port) Reset()
func (*Pod_Container_Port) String ¶
func (m *Pod_Container_Port) String() string
func (*Pod_Container_Port) XXX_DiscardUnknown ¶ added in v1.4.0
func (m *Pod_Container_Port) XXX_DiscardUnknown()
func (*Pod_Container_Port) XXX_Marshal ¶ added in v1.4.0
func (m *Pod_Container_Port) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*Pod_Container_Port) XXX_Merge ¶ added in v1.4.0
func (m *Pod_Container_Port) XXX_Merge(src proto.Message)
func (*Pod_Container_Port) XXX_Size ¶ added in v1.4.0
func (m *Pod_Container_Port) XXX_Size() int
func (*Pod_Container_Port) XXX_Unmarshal ¶ added in v1.4.0
func (m *Pod_Container_Port) XXX_Unmarshal(b []byte) error
type Pod_Container_Port_Protocol ¶
type Pod_Container_Port_Protocol int32
Protocol defines network protocols supported for container ports.
const ( Pod_Container_Port_TCP Pod_Container_Port_Protocol = 0 Pod_Container_Port_UDP Pod_Container_Port_Protocol = 1 )
func (Pod_Container_Port_Protocol) EnumDescriptor ¶
func (Pod_Container_Port_Protocol) EnumDescriptor() ([]byte, []int)
func (Pod_Container_Port_Protocol) String ¶
func (x Pod_Container_Port_Protocol) String() string
type Pod_Label ¶
type Pod_Label struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Label is a key/value pair attached to an object (pod in this case). Labels are used to organize and to select subsets of objects.
func (*Pod_Label) Descriptor ¶
func (*Pod_Label) ProtoMessage ¶
func (*Pod_Label) ProtoMessage()
func (*Pod_Label) XXX_DiscardUnknown ¶ added in v1.4.0
func (m *Pod_Label) XXX_DiscardUnknown()
func (*Pod_Label) XXX_Marshal ¶ added in v1.4.0
func (*Pod_Label) XXX_Unmarshal ¶ added in v1.4.0
Click to show internal directories.
Click to hide internal directories.