diff --git a/rpc/cloudagent/network/moc_cloudagent_networkinterface.pb.go b/rpc/cloudagent/network/moc_cloudagent_networkinterface.pb.go index a773aad6..20903a3c 100644 --- a/rpc/cloudagent/network/moc_cloudagent_networkinterface.pb.go +++ b/rpc/cloudagent/network/moc_cloudagent_networkinterface.pb.go @@ -201,6 +201,7 @@ type IpConfiguration struct { Allocation common.IPAllocationMethod `protobuf:"varint,6,opt,name=allocation,proto3,enum=moc.IPAllocationMethod" json:"allocation,omitempty"` Gateway string `protobuf:"bytes,7,opt,name=gateway,proto3" json:"gateway,omitempty"` InboundNatRules []*InboundNatRule `protobuf:"bytes,8,rep,name=inboundNatRules,proto3" json:"inboundNatRules,omitempty"` + Tags *common.Tags `protobuf:"bytes,9,opt,name=tags,proto3" json:"tags,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -287,6 +288,13 @@ func (m *IpConfiguration) GetInboundNatRules() []*InboundNatRule { return nil } +func (m *IpConfiguration) GetTags() *common.Tags { + if m != nil { + return m.Tags + } + return nil +} + type NetworkInterface struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` @@ -359,6 +367,17 @@ func (m *NetworkInterface) GetIpConfigurations() []*IpConfiguration { return nil } +func (m *NetworkInterface) GetPrimaryIpConfiguration() *IpConfiguration { + if m != nil { + for _, ipConfig := range m.IpConfigurations { + if ipConfig.Primary { + return ipConfig + } + } + } + return nil +} + func (m *NetworkInterface) GetMacaddress() string { if m != nil { return m.Macaddress diff --git a/rpc/cloudagent/network/networkinterface/moc_cloudagent_networkinterface.proto b/rpc/cloudagent/network/networkinterface/moc_cloudagent_networkinterface.proto index b1df61cd..2459c4de 100644 --- a/rpc/cloudagent/network/networkinterface/moc_cloudagent_networkinterface.proto +++ b/rpc/cloudagent/network/networkinterface/moc_cloudagent_networkinterface.proto @@ -33,6 +33,7 @@ message IpConfiguration { IPAllocationMethod allocation = 6; string gateway = 7 [(sensitive) = true]; repeated InboundNatRule inboundNatRules = 8; + Tags tags = 9; } message NetworkInterface {