otcextensions.sdk.vpc.v1.subnet

The VPC Subnet Class

The Subnet class inherits from Resource.

class otcextensions.sdk.vpc.v1.subnet.Subnet(_synchronized=False, connection=None, **attrs)

The base resource

Parameters
  • _synchronized (bool) – This is not intended to be used directly. See new() and existing().

  • connection (openstack.connection.Connection) – Reference to the Connection being used. Defaults to None to allow Resource objects to be used without an active Connection, such as in unit tests. Use of self._connection in Resource code should protect itself with a check for None.

cidr

Specifies the subnet CIDR block.

gateway_ip

Specifies the gateway of the subnet.

dhcp_enable

Specifies whether DHCP is enabled for the subnet.

primary_dns

Specifies the IP address of DNS server 1 on the subnet.

secondary_dns

Specifies the IP address of DNS server 2 on the subnet.

dns_list

Specifies the DNS server address list of a subnet. This field is required if use more than two DNS servers.

availability_zone

Specifies the AZ to which the subnet belongs

vpc_id

Specifies the ID of the VPC to which the subnet belongs.

extra_dhcp_opts

Specifies the NTP server address configured for the subnet.