types

package
v0.0.0-...-1d39891 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2020 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionListType

type ActionListType struct {
	SimpleAction          string           `json:"simple_action"`
	GatewayName           string           `json:"gateway_name,omitempty" structs:",omitempty"`
	ApplyService          []string         `json:"apply_service,omitempty" structs:",omitempty"`
	MirrorTo              MirrorActionType `json:"mirror_to,omitempty" structs:",omitempty"`
	AssignRoutingInstance string           `json:"assign_routing_instance,omitempty" structs:",omitempty"`
	Log                   bool             `json:"log,omitempty" structs:",omitempty"`
	Alert                 bool             `json:"alert,omitempty" structs:",omitempty"`
	QosAction             string           `json:"qos_action,omitempty" structs:",omitempty"`
	HostBasedService      bool             `json:"host_based_service,omitempty" structs:",omitempty"`
}

type AddressType

type AddressType struct {
	VirtualNetwork string       `json:"virtual_network"`
	SecurityGroup  string       `json:"security_group"`
	NetworkPolicy  string       `json:"network_policy"`
	SubnetList     []SubnetType `json:"subnet_list,omitempty" structs:",omitempty"`
}

type CommonAttribute

type CommonAttribute struct {
	UUID   string   `json:"uuid"`
	Name   string   `json:"name"`
	FqName []string `json:"fq_name"`
	RBAC   Perms2   `json:"perms2"`
}

type Domain

type Domain struct {
	CommonAttribute
	ServiceTemplateRefs []Reference `json:"service_templates"`
	ProjectRefs         []Reference `json:"projects"`
}

func (Domain) ListProjectIDs

func (d Domain) ListProjectIDs() (uuids []string)

func (Domain) ListServiceTemplateIDs

func (d Domain) ListServiceTemplateIDs() (uuids []string)

type EcmpHashingIncludeFields

type EcmpHashingIncludeFields struct {
	HashingConfigured bool `json:"hashing_configured,omitempty"`
	SourceIp          bool `json:"source_ip,omitempty"`
	DestinationIp     bool `json:"destination_ip,omitempty"`
	IpProtocol        bool `json:"ip_protocol,omitempty"`
	SourcePort        bool `json:"source_port,omitempty"`
	DestinationPort   bool `json:"destination_port,omitempty"`
}

type MacAddress

type MacAddress struct {
	MacAddresses []string `json:"mac_address"`
}

type MirrorActionType

type MirrorActionType struct {
	AnalyzerName             string             `json:"analyzer_name,omitempty" structs:",omitempty"`
	Encapsulation            string             `json:"encapsulation,omitempty" structs:",omitempty"`
	AnalyzerIpAddress        string             `json:"analyzer_ip_address"`
	AnalyzerMacAddress       string             `json:"analyzer_mac_address,omitempty" structs:",omitempty"`
	RoutingInstance          string             `json:"routing_instance"`
	UdpPort                  int                `json:"udp_port,omitempty" structs:",omitempty"`
	JuniperHeader            bool               `json:"juniper_header,omitempty" structs:",omitempty"`
	NhMode                   string             `json:"nh_mode,omitempty" structs:",omitempty"`
	StaticNhHeader           StaticMirrorNhType `json:"static_nh_header,omitempty" structs:",omitempty"`
	NicAssistedMirroring     bool               `json:"nic_assisted_mirroring,omitempty" structs:",omitempty"`
	NicAssistedMirroringVlan int                `json:"nic_assisted_mirroring_vlan,omitempty" structs:",omitempty"`
}

type NetworkPolicy

type NetworkPolicy struct {
	CommonAttribute
	PolicyRules        `json:"network_policy_entries"`
	VirtualNetworkRefs []Reference `json:"virtual_network_back_refs"`
	ProjectRef         string      `json:"parent_uuid"`
}

func (NetworkPolicy) ListProjectIDs

func (np NetworkPolicy) ListProjectIDs() (uuids []string)

func (NetworkPolicy) ListRules

func (np NetworkPolicy) ListRules() (rules []NetworkPolicyRule)

NOTE: Filter out all rules without an UUID

func (NetworkPolicy) ListVirtualNetworkIDs

func (np NetworkPolicy) ListVirtualNetworkIDs() (uuids []string)

type NetworkPolicyRule

type NetworkPolicyRule struct {
	UUID         string         `json:"rule_uuid,omitempty" structs:",omitempty"`
	Direction    string         `json:"direction"`
	Protocol     string         `json:"protocol"`
	SrcAddresses []AddressType  `json:"src_addresses"`
	SrcPorts     []PortType     `json:"src_ports"`
	Application  []string       `json:"application,omitempty" structs:",omitempty"`
	DstAddresses []AddressType  `json:"dst_addresses"`
	DstPorts     []PortType     `json:"dst_ports"`
	ActionList   ActionListType `json:"action_list"`
	Ethertype    string         `json:"ethertype"`
	Created      string         `json:"created,omitempty" structs:",omitempty"`
	LastModified string         `json:"last_modified,omitempty" structs:",omitempty"`
}

func (NetworkPolicyRule) ListServiceInstances

func (npr NetworkPolicyRule) ListServiceInstances() (fqNames []string)

type Perms2

type Perms2 struct {
	OwnerTenant string      `json:"owner"`
	OwnerAccess int         `json:"owner_access"`
	OtherAccess int         `json:"other_access,omitempty" structs:",omitempty"`
	ShareTo     []ShareType `json:"share,omitempty" structs:",omitempty"`
}

type PolicyRules

type PolicyRules struct {
	Rules []NetworkPolicyRule `json:"policy_rule"`
}

type PortTuple

type PortTuple struct {
	CommonAttribute
	VirtualMachineInterfaceRefs []Reference `json:"virtual_machine_interface_back_refs,omitempty"`
	ServiceInstanceRef          string      `json:"parent_uuid"`
}

func (PortTuple) ListServiceInstanceIDs

func (pt PortTuple) ListServiceInstanceIDs() (uuids []string)

func (PortTuple) ListVirtualMachineInterfaceIDs

func (pt PortTuple) ListVirtualMachineInterfaceIDs() (uuids []string)

type PortType

type PortType struct {
	StartPort int `json:"start_port"`
	EndPort   int `json:"end_port"`
}

type Project

type Project struct {
	CommonAttribute
	Quota              Quota       `json:"quota"`
	VirtualNetworkRefs []Reference `json:"virtual_networks"`
	DomainRef          string      `json:"parent_uuid"`
}

func (Project) ListDomainIDs

func (p Project) ListDomainIDs() (uuids []string)

func (Project) ListVirtualNetworkIDs

func (p Project) ListVirtualNetworkIDs() (uuids []string)

type Quota

type Quota struct {
	Defaults                  int `json:"defaults,omitempty" structs:",omitempty"`
	FloatingIp                int `json:"floating_ip,omitempty" structs:",omitempty"`
	InstanceIp                int `json:"instance_ip,omitempty" structs:",omitempty"`
	VirtualMachineInterface   int `json:"virtual_machine_interface,omitempty" structs:",omitempty"`
	VirtualNetwork            int `json:"virtual_network,omitempty" structs:",omitempty"`
	VirtualRouter             int `json:"virtual_router,omitempty" structs:",omitempty"`
	VirtualDNS                int `json:"virtual_DNS,omitempty" structs:",omitempty"`
	VirtualDNSRecord          int `json:"virtual_DNS_record,omitempty" structs:",omitempty"`
	BgpRouter                 int `json:"bgp_router,omitempty" structs:",omitempty"`
	NetworkIpam               int `json:"network_ipam,omitempty" structs:",omitempty"`
	AccessControlList         int `json:"access_control_list,omitempty" structs:",omitempty"`
	NetworkPolicy             int `json:"network_policy,omitempty" structs:",omitempty"`
	FloatingIpPool            int `json:"floating_ip_pool,omitempty" structs:",omitempty"`
	ServiceTemplate           int `json:"service_template,omitempty" structs:",omitempty"`
	ServiceInstance           int `json:"service_instance,omitempty" structs:",omitempty"`
	LogicalRouter             int `json:"logical_router,omitempty" structs:",omitempty"`
	SecurityGroup             int `json:"security_group,omitempty" structs:",omitempty"`
	SecurityGroupRule         int `json:"security_group_rule,omitempty" structs:",omitempty"`
	Subnet                    int `json:"subnet,omitempty" structs:",omitempty"`
	GlobalVrouterConfig       int `json:"global_vrouter_config,omitempty" structs:",omitempty"`
	LoadbalancerPool          int `json:"loadbalancer_pool,omitempty" structs:",omitempty"`
	LoadbalancerMember        int `json:"loadbalancer_member,omitempty" structs:",omitempty"`
	LoadbalancerHealthmonitor int `json:"loadbalancer_healthmonitor,omitempty" structs:",omitempty"`
	VirtualIp                 int `json:"virtual_ip,omitempty" structs:",omitempty"`
	SecurityLoggingObject     int `json:"security_logging_object,omitempty" structs:",omitempty"`
	RouteTable                int `json:"route_table,omitempty" structs:",omitempty"`
	FirewallGroup             int `json:"firewall_group,omitempty" structs:",omitempty"`
	FirewallPolicy            int `json:"firewall_policy,omitempty" structs:",omitempty"`
	FirewallRule              int `json:"firewall_rule,omitempty" structs:",omitempty"`
	HostBasedService          int `json:"host_based_service,omitempty" structs:",omitempty"`
}

type Reference

type Reference struct {
	UUID string `json:"uuid"`
}

type ServiceInstance

type ServiceInstance struct {
	CommonAttribute
	ServiceInstanceProperty `json:"service_instance_properties"`
	PortTupleRefs           []Reference `json:"port_tuples"`
	ServiceTemplateRefs     []Reference `json:"service_template_refs"`
	ProjectRef              string      `json:"parent_uuid"`
}

func (ServiceInstance) ListPortTupleIDs

func (si ServiceInstance) ListPortTupleIDs() (uuids []string)

func (ServiceInstance) ListProjectIDs

func (si ServiceInstance) ListProjectIDs() (uuids []string)

func (ServiceInstance) ListServiceTemplateIDs

func (si ServiceInstance) ListServiceTemplateIDs() (uuids []string)

func (ServiceInstance) ListVirtualNetworks

func (si ServiceInstance) ListVirtualNetworks() (uuids []string)

type ServiceInstanceInterface

type ServiceInstanceInterface struct {
	VirtualNetwork string `json:"virtual_network"`
}

type ServiceInstanceProperty

type ServiceInstanceProperty struct {
	AutoPolicy                bool                       `json:"auto_policy,omitempty" structs:",omitempty"`
	AvailabilityZone          string                     `json:"availability_zone,omitempty" structs:",omitempty"`
	InterfaceList             []ServiceInstanceInterface `json:"interface_list"`
	ServiceScaleOut           `json:"scale_out,omitempty" structs:",omitempty"`
	HAMode                    string `json:"ha_mode,omitempty" structs:",omitempty"`
	ServiceVirtualizationType string `json:"service_virtualization_type,omitempty" structs:",omitempty"`
}

type ServiceScaleOut

type ServiceScaleOut struct {
	MaxInstances    int  `json:"max_instances"`
	EnableAutoScale bool `json:"auto_scale"`
}

type ServiceTemplate

type ServiceTemplate struct {
	CommonAttribute
	ServiceTemplateProperty `json:"service_template_properties"`
	Domain                  string `json:"parent_uuid"`
}

func (ServiceTemplate) ListDomainIDs

func (st ServiceTemplate) ListDomainIDs() (uuids []string)

type ServiceTemplateInterfaceType

type ServiceTemplateInterfaceType struct {
	ServiceInterfaceType string `json:"service_interface_type"`
	SharedIp             bool   `json:"shared_ip,omitempty" structs:",omitempty"`
	StaticRouteEnable    bool   `json:"static_route_enable,omitempty" structs:",omitempty"`
}

type ServiceTemplateProperty

type ServiceTemplateProperty struct {
	Version                   int                            `json:"version,omitempty" structs:",omitempty"`
	ServiceMode               string                         `json:"service_mode"`
	ServiceType               string                         `json:"service_type"`
	ImageName                 string                         `json:"image_name,omitempty" structs:",omitempty"`
	ServiceScaling            bool                           `json:"service_scaling,omitempty" structs:",omitempty"`
	InterfaceType             []ServiceTemplateInterfaceType `json:"interface_type"`
	Flavor                    string                         `json:"flavor,omitempty" structs:",omitempty"`
	ServiceVirtualizationType string                         `json:"service_virtualization_type,omitempty" structs:",omitempty"`
	AvailabilityZoneEnable    bool                           `json:"availability_zone_enable,omitempty" structs:",omitempty"`
	VrouterInstanceType       string                         `json:"vrouter_instance_type,omitempty" structs:",omitempty"`
	InstanceData              string                         `json:"instance_data,omitempty" structs:",omitempty"`
}

type ShareType

type ShareType struct {
	Tenant       string `json:"tenant"`
	TenantAccess int    `json:"tenant_access"`
}

type StaticMirrorNhType

type StaticMirrorNhType struct {
	VtepDstIpAddress  string `json:"vtep_dst_ip_address"`
	VtepDstMacAddress string `json:"vtep_dst_mac_address,omitempty" structs:",omitempty"`
	Vni               int    `json:"vni"`
}

type SubnetType

type SubnetType struct {
	IpPrefix    string `json:"ip_prefix,omitempty" structs:",omitempty"`
	IpPrefixLen int    `json:"ip_prefix_len,omitempty" structs:",omitempty"`
}

type VirtualMachine

type VirtualMachine struct {
	CommonAttribute
	InterfaceRefs []Reference `json:"virtual_machine_interface_back_refs"`
	ServerType    string      `json:"server_type"`
}

func (VirtualMachine) ListVirtualMachineInterfaceIDs

func (vm VirtualMachine) ListVirtualMachineInterfaceIDs() (uuids []string)

type VirtualMachineInterface

type VirtualMachineInterface struct {
	CommonAttribute
	MacAddress                      `json:"virtual_machine_interface_mac_addresses"`
	VirtualMachineInterfaceProperty `json:"virtual_machine_interface_properties"`
	EcmpHashingIncludeFields        `json:"ecmp_hashing_include_fields"`
	VirtualMachineRefs              []Reference `json:"virtual_machine_refs"`
	// VirtualNetworkRefs              []Reference `json:"virtual_network_refs"`
	PortTupleRefs []Reference `json:"port_tuple_refs"`
}

func (VirtualMachineInterface) ListPortTupleIDs

func (vmi VirtualMachineInterface) ListPortTupleIDs() (uuids []string)

func (VirtualMachineInterface) ListVirtualMachineIDs

func (vmi VirtualMachineInterface) ListVirtualMachineIDs() (uuids []string)

type VirtualMachineInterfaceProperty

type VirtualMachineInterfaceProperty struct {
	ServiceInterfaceType string `json:"service_interface_type,omitempty" structs:",omitempty"`
	LocalPreference      int    `json:"local_preference,omitempty" structs:",omitempty"`
	SubInterfaceVlanTag  int    `json:"sub_interface_vlan_tag,omitempty" structs:",omitempty"`
	MaxFlows             int    `json:"max_flows,omitempty" structs:",omitempty"`
}

type VirtualNetwork

type VirtualNetwork struct {
	CommonAttribute
	VirtualNetworkProperty   `json:"virtual_network_properties"`
	EcmpHashingIncludeFields `json:"ecmp_hashing_include_fields"`
	MultiServiceChainEnabled bool   `json:"multi_policy_service_chains_enabled"`
	Shareable                bool   `json:"is_shared"`
	ProjectRef               string `json:"parent_uuid"`
}

func (VirtualNetwork) ListProjectIDs

func (vn VirtualNetwork) ListProjectIDs() (uuids []string)

type VirtualNetworkProperty

type VirtualNetworkProperty struct {
	AllowTransit           bool   `json:"allow_transit,omitempty" structs:",omitempty"`
	NetworkId              int    `json:"network_id,omitempty" structs:",omitempty"`
	VxlanNetworkIdentifier int    `json:"vxlan_network_identifier"`
	ForwardingMode         string `json:"forwarding_mode,omitempty" structs:",omitempty"`
	Rpf                    string `json:"rpf,omitempty" structs:",omitempty"`
	MirrorDestination      bool   `json:"mirror_destination,omitempty" structs:",omitempty"`
	MaxFlows               int    `json:"max_flows,omitempty" structs:",omitempty"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL