From a8a1643ee065acdb2d004a0437cb591be970e01f Mon Sep 17 00:00:00 2001 From: Blake Harnden <32446120+bharnden@users.noreply.github.com> Date: Wed, 29 Jan 2020 17:08:36 -0800 Subject: [PATCH] added configuration for loading custom config services --- daemon/core/emulator/coreemu.py | 3 +++ daemon/data/core.conf | 1 + 2 files changed, 4 insertions(+) diff --git a/daemon/core/emulator/coreemu.py b/daemon/core/emulator/coreemu.py index 4041cf40..6c6f1418 100644 --- a/daemon/core/emulator/coreemu.py +++ b/daemon/core/emulator/coreemu.py @@ -61,6 +61,9 @@ class CoreEmu: self.service_manager = ConfigServiceManager() config_services_path = os.path.abspath(os.path.dirname(configservices.__file__)) self.service_manager.load(config_services_path) + custom_dir = self.config.get("custom_config_services_dir") + if custom_dir: + self.service_manager.load(custom_dir) # catch exit event atexit.register(self.shutdown) diff --git a/daemon/data/core.conf b/daemon/data/core.conf index aa1238d5..13b50785 100644 --- a/daemon/data/core.conf +++ b/daemon/data/core.conf @@ -14,6 +14,7 @@ frr_sbin_search = "/usr/local/sbin /usr/sbin /usr/lib/frr" # this may be a comma-separated list, and directory names should be unique # and not named 'services' #custom_services_dir = /home/username/.core/myservices +#custom_config_services_dir = /home/username/.coretk/custom_services # uncomment to establish a standalone control backchannel for accessing nodes # (overriden by the session option of the same name)