1
0
mirror of https://github.com/rancher/types.git synced 2025-09-17 23:38:20 +00:00

Merge pull request #333 from alena1108/addresses

Address to addresses on public endpoint
This commit is contained in:
Alena Prokharchyk
2018-03-30 16:08:14 -07:00
committed by GitHub
6 changed files with 62 additions and 31 deletions

View File

@@ -233,13 +233,19 @@ type NodeDriverSpec struct {
}
type PublicEndpoint struct {
NodeName string `json:"nodeName,omitempty" norman:"type=reference[/v3/schemas/node],nocreate,noupdate"`
Address string `json:"address,omitempty" norman:"nocreate,noupdate"`
Port int32 `json:"port,omitempty" norman:"nocreate,noupdate"`
Protocol string `json:"protocol,omitempty" norman:"nocreate,noupdate"`
// for node port service
NodeName string `json:"nodeName,omitempty" norman:"type=reference[/v3/schemas/node],nocreate,noupdate"`
Addresses []string `json:"addresses,omitempty" norman:"nocreate,noupdate"`
Port int32 `json:"port,omitempty" norman:"nocreate,noupdate"`
Protocol string `json:"protocol,omitempty" norman:"nocreate,noupdate"`
// for node port service endpoint
ServiceName string `json:"serviceName,omitempty" norman:"type=reference[service],nocreate,noupdate"`
// for host port
// for host port endpoint
PodName string `json:"podName,omitempty" norman:"type=reference[pod],nocreate,noupdate"`
//serviceName and podName are mutually exclusive
// for ingress endpoint. ServiceName, podName, ingressName are mutually exclusive
IngressName string `json:"ingressName,omitempty" norman:"type=reference[ingress],nocreate,noupdate"`
// Hostname/path are set for Ingress endpoints
Hostname string `json:"hostname,omitempty" norman:"nocreate,noupdate"`
Path string `json:"path,omitempty" norman:"nocreate,noupdate"`
// True when endpoint is exposed on every node
AllNodes bool `json:"allNodes" norman:"nocreate,noupdate"`
}

View File

@@ -5379,6 +5379,11 @@ func (in *ProjectStatus) DeepCopy() *ProjectStatus {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *PublicEndpoint) DeepCopyInto(out *PublicEndpoint) {
*out = *in
if in.Addresses != nil {
in, out := &in.Addresses, &out.Addresses
*out = make([]string, len(*in))
copy(*out, *in)
}
return
}

View File

@@ -85,18 +85,21 @@ type SSHAuth struct {
type NamespacedSSHAuth SSHAuth
type PublicEndpoint struct {
NodeName string `json:"nodeName,omitempty" norman:"type=reference[/v3/schemas/node],nocreate,noupdate"`
Address string `json:"address,omitempty" norman:"nocreate,noupdate"`
Port int32 `json:"port,omitempty" norman:"nocreate,noupdate"`
Protocol string `json:"protocol,omitempty" norman:"nocreate,noupdate"`
// for node port service
NodeName string `json:"nodeName,omitempty" norman:"type=reference[/v3/schemas/node],nocreate,noupdate"`
Addresses []string `json:"addresses,omitempty" norman:"nocreate,noupdate"`
Port int32 `json:"port,omitempty" norman:"nocreate,noupdate"`
Protocol string `json:"protocol,omitempty" norman:"nocreate,noupdate"`
// for node port service endpoint
ServiceName string `json:"serviceName,omitempty" norman:"type=reference[service],nocreate,noupdate"`
// for host port
// for host port endpoint
PodName string `json:"podName,omitempty" norman:"type=reference[pod],nocreate,noupdate"`
//serviceName and podName are mutually exclusive
// for ingress endpoint. ServiceName, podName, ingressName are mutually exclusive
IngressName string `json:"ingressName,omitempty" norman:"type=reference[ingress],nocreate,noupdate"`
// Hostname/path are set for Ingress endpoints
Hostname string `json:"hostname,omitempty" norman:"nocreate,noupdate"`
Path string `json:"path,omitempty" norman:"nocreate,noupdate"`
// hostname and part is for global load balancer
// True when endpoint is exposed on every node
AllNodes bool `json:"allNodes" norman:"nocreate,noupdate"`
}
type Workload struct {

View File

@@ -946,6 +946,11 @@ func (in *NamespacedServiceAccountTokenList) DeepCopyObject() runtime.Object {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *PublicEndpoint) DeepCopyInto(out *PublicEndpoint) {
*out = *in
if in.Addresses != nil {
in, out := &in.Addresses, &out.Addresses
*out = make([]string, len(*in))
copy(*out, *in)
}
return
}