updates to fail early for required executables that are not in PATH
This commit is contained in:
parent
2a5c913a62
commit
503fa754a9
30 changed files with 128 additions and 132 deletions
|
@ -14,17 +14,16 @@ import threading
|
|||
from builtins import range
|
||||
from socket import AF_INET, AF_INET6
|
||||
|
||||
from core import CoreCommandError, constants, utils
|
||||
from core import constants, utils
|
||||
from core.emulator.data import LinkData, NodeData
|
||||
from core.emulator.enumerations import LinkTypes, NodeTypes
|
||||
from core.errors import CoreCommandError
|
||||
from core.nodes import client, ipaddress
|
||||
from core.nodes.interface import CoreInterface, TunTap, Veth
|
||||
from core.nodes.netclient import LinuxNetClient, OvsNetClient
|
||||
|
||||
_DEFAULT_MTU = 1500
|
||||
|
||||
utils.check_executables([constants.IP_BIN])
|
||||
|
||||
|
||||
class NodeBase(object):
|
||||
"""
|
||||
|
|
|
@ -8,7 +8,8 @@ import logging
|
|||
import os
|
||||
from subprocess import PIPE, Popen
|
||||
|
||||
from core import CoreCommandError, constants, utils
|
||||
from core import constants, utils
|
||||
from core.errors import CoreCommandError
|
||||
|
||||
|
||||
class VnodeClient(object):
|
||||
|
|
|
@ -2,8 +2,9 @@ import json
|
|||
import logging
|
||||
import os
|
||||
|
||||
from core import CoreCommandError, utils
|
||||
from core import utils
|
||||
from core.emulator.enumerations import NodeTypes
|
||||
from core.errors import CoreCommandError
|
||||
from core.nodes.base import CoreNode
|
||||
|
||||
|
||||
|
|
|
@ -6,9 +6,8 @@ import logging
|
|||
import time
|
||||
from builtins import int, range
|
||||
|
||||
from core import CoreCommandError, constants, utils
|
||||
|
||||
utils.check_executables([constants.IP_BIN])
|
||||
from core import constants, utils
|
||||
from core.errors import CoreCommandError
|
||||
|
||||
|
||||
class CoreInterface(object):
|
||||
|
|
|
@ -3,8 +3,9 @@ import logging
|
|||
import os
|
||||
import time
|
||||
|
||||
from core import CoreCommandError, utils
|
||||
from core import utils
|
||||
from core.emulator.enumerations import NodeTypes
|
||||
from core.errors import CoreCommandError
|
||||
from core.nodes.base import CoreNode
|
||||
|
||||
|
||||
|
|
|
@ -9,17 +9,14 @@ import threading
|
|||
import time
|
||||
from socket import AF_INET, AF_INET6
|
||||
|
||||
from core import CoreCommandError, CoreError, constants, utils
|
||||
from core import constants, utils
|
||||
from core.emulator.data import LinkData
|
||||
from core.emulator.enumerations import LinkTypes, NodeTypes, RegisterTlvs
|
||||
from core.errors import CoreCommandError, CoreError
|
||||
from core.nodes import ipaddress
|
||||
from core.nodes.base import CoreNetworkBase
|
||||
from core.nodes.interface import GreTap, Veth
|
||||
|
||||
utils.check_executables(
|
||||
[constants.BRCTL_BIN, constants.IP_BIN, constants.EBTABLES_BIN, constants.TC_BIN]
|
||||
)
|
||||
|
||||
ebtables_lock = threading.Lock()
|
||||
|
||||
|
||||
|
|
|
@ -7,8 +7,9 @@ import os
|
|||
import subprocess
|
||||
import threading
|
||||
|
||||
from core import CoreCommandError, constants, utils
|
||||
from core import constants, utils
|
||||
from core.emulator.enumerations import NodeTypes
|
||||
from core.errors import CoreCommandError
|
||||
from core.nodes.base import CoreNodeBase
|
||||
from core.nodes.interface import CoreInterface
|
||||
from core.nodes.network import CoreNetwork, GreTap
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue