openstack.network.v2.port

openstack.network.v2.port

The Port Class

The Port class inherits from Resource.

class openstack.network.v2.port.Port(attrs=None, loaded=False)

Construct a Resource to interact with a service’s REST API.

The Resource class offers two class methods to construct resource objects, which are preferrable to entering through this initializer. See Resource.new() and Resource.existing().

Parameters:
  • attrs (dict) – The attributes to set when constructing this Resource.
  • loaded (bool) – True if this Resource exists on the server, False if it does not.
allowed_address_pairs = None

Allowed address pairs.

binding_host_id = None

The ID of the host where the port is allocated. In some cases, different implementations can run on different hosts.

binding_profile = None

A dictionary the enables the application running on the specified host to pass and receive vif port-specific information to the plug-in. Type: dict

binding_vif_details = None

Read-only. A dictionary that enables the application to pass information about functions that the Networking API provides. To enable or disable port filtering features such as security group and anti-MAC/IP spoofing, specify port_filter: True or port_filter: False. Type: dict

binding_vif_type = None

Read-only. The vif type for the specified port.

binding_vnic_type = None

The vnic type that is bound to the neutron port.

In POST and PUT operations, specify a value of normal (virtual nic), direct (pci passthrough), or macvtap (virtual interface with a tap-like software interface). These values support SR-IOV PCI passthrough networking. The ML2 plug-in supports the vnic_type.

In GET operations, the binding:vnic_type extended attribute is visible to only port owners and administrative users.

created_at = None

Timestamp when the port was created.

description = None

The port description.

device_id = None

Device ID of this port.

device_owner = None

Device owner of this port (e.g. network:dhcp).

dns_assignment = None

DNS assignment for the port.

dns_name = None

DNS name for the port.

extra_dhcp_opts = None

Extra DHCP options.

fixed_ips = None

IP addresses for the port. Includes the IP address and subnet ID.

is_admin_state_up = None

The administrative state of the port, which is up True or down False. Type: bool

is_port_security_enabled = None

The port security status, which is enabled True or disabled False. Type: bool Default: False

mac_address = None

The MAC address of the port.

name = None

The port name.

network_id = None

The ID of the attached network.

project_id = None

The ID of the project who owns the network. Only administrative users can specify a project ID other than their own.

security_group_ids = None

The IDs of any attached security groups. Type: list of strs of the security group IDs

status = None

The port status. Value is ACTIVE or DOWN.

updated_at = None

Timestamp when the port was last updated.

Creative Commons Attribution 3.0 License

Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.