2018-02-22 11:58:36 +01:00
|
|
|
import importlib.util
|
|
|
|
import sys
|
|
|
|
|
|
|
|
try:
|
2018-04-03 09:02:19 +02:00
|
|
|
spec = importlib.util.spec_from_file_location('configuration', '/etc/netbox/config/configuration.py')
|
2018-02-22 11:58:36 +01:00
|
|
|
module = importlib.util.module_from_spec(spec)
|
|
|
|
spec.loader.exec_module(module)
|
|
|
|
sys.modules['netbox.configuration'] = module
|
|
|
|
except:
|
|
|
|
raise ImportError('')
|