module documentation

Logical units dealing with networks.

Class LUNetworkAdd Logical unit for creating networks.
Class LUNetworkConnect Connect a network to a nodegroup
Class LUNetworkDisconnect Disconnect a network to a nodegroup
Class LUNetworkRemove No class docstring; 0/2 instance variable, 0/2 constant, 4/5 methods documented
Class LUNetworkRename No class docstring; 0/2 instance variable, 0/2 constant, 4/5 methods documented
Class LUNetworkSetParams Modifies the parameters of a network.
Function _BuildNetworkHookEnv Builds network related env variables for hooks
Function _FmtNetworkConflict Utility for _NetworkConflictCheck.
Function _NetworkConflictCheck Checks for network interface conflicts with a network.
def _BuildNetworkHookEnv(name, subnet, gateway, network6, gateway6, mac_prefix, tags):

Builds network related env variables for hooks

This builds the hook environment from individual variables.

Parameters
name:stringthe name of the network
subnet:stringthe ipv4 subnet
gateway:stringthe ipv4 gateway
network6:stringthe ipv6 subnet
gateway6:stringthe ipv6 gateway
mac_prefix:stringthe mac_prefix
tags:listthe tags of the network
def _FmtNetworkConflict(details):

Utility for _NetworkConflictCheck.

def _NetworkConflictCheck(lu, check_fn, action, instances):

Checks for network interface conflicts with a network.

Parameters
lu:LogicalUnitUndocumented
check_fn:callable receiving one parameter (objects.NIC) and returning booleanFunction checking for conflict
action:stringPart of error message (see code)
instances:list of instance objectsthe instances to check
Raises
errors.OpPrereqErrorIf conflicting IP addresses are found.