daemon: cleaned up requirement check, updated github workflow to modify correct file

This commit is contained in:
Blake Harnden 2020-06-23 09:24:40 -07:00
parent e0c9f9c832
commit 8f19ad057c
2 changed files with 6 additions and 7 deletions

View file

@ -18,7 +18,7 @@ jobs:
cd daemon
cp setup.py.in setup.py
cp core/constants.py.in core/constants.py
sed -i 's/True/False/g' core/constants.py
sed -i 's/required=True/required=False/g' core/emulator/coreemu.py
pipenv sync --dev
- name: isort
run: |

View file

@ -79,15 +79,14 @@ class CoreEmu:
:return: nothing
:raises core.errors.CoreError: when an executable does not exist on path
"""
for requirement in COMMON_REQUIREMENTS:
utils.which(requirement, required=True)
requirements = COMMON_REQUIREMENTS
use_ovs = self.config.get("ovs") == "True"
if use_ovs:
for requirement in OVS_REQUIREMENTS:
utils.which(requirement, required=True)
requirements += OVS_REQUIREMENTS
else:
for requirement in VCMD_REQUIREMENTS:
utils.which(requirement, required=True)
requirements += VCMD_REQUIREMENTS
for requirement in requirements:
utils.which(requirement, required=True)
def load_services(self) -> None:
"""