New methods with nodes

Signed-off-by: Dmitriy Zayakin <d.zayakin@yadro.com>
This commit is contained in:
Dmitriy Zayakin 2023-06-05 12:00:06 +03:00 committed by ylukoyan
parent e9777b63cd
commit 26a78c0eae
10 changed files with 170 additions and 10 deletions

View file

@ -19,6 +19,7 @@ class NodeBase(ABC):
id: str
name: str
host: Host
_process_name: str
def __init__(self, id, name, host) -> None:
self.id = id
@ -48,6 +49,9 @@ class NodeBase(ABC):
def get_service_systemctl_name(self) -> str:
return self._get_attribute(ConfigAttributes.SERVICE_NAME)
def get_process_name(self) -> str:
return self._process_name
def start_service(self):
self.host.start_service(self.name)