From d480a516420022710f0b9fd2ac528fa0e87fc275 Mon Sep 17 00:00:00 2001 From: Ankush Patel Date: Fri, 18 Aug 2023 15:28:26 -0700 Subject: [PATCH] wsl2 is linux --- spice_agent/daemons/actions.py | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/spice_agent/daemons/actions.py b/spice_agent/daemons/actions.py index baf7e90..72829a9 100644 --- a/spice_agent/daemons/actions.py +++ b/spice_agent/daemons/actions.py @@ -27,10 +27,7 @@ def install(self): if self.os_family == "Darwin": full_launch_agent_install() elif self.os_family == "Linux": - if "WSL2" in platform.platform(): - full_service_install() - else: - print("Not Implemented") + full_service_install() elif self.os_family == "Windows": print("Not Implemented") return result @@ -40,10 +37,7 @@ def uninstall(self): if self.os_family == "Darwin": full_launch_agent_uninstall() elif self.os_family == "Linux": - if "WSL2" in platform.platform(): - full_service_uninstall() - else: - print("Not Implemented") + full_service_uninstall() elif self.os_family == "Windows": print("Not Implemented") return result @@ -53,10 +47,7 @@ def stop(self) -> bool: if self.os_family == "Darwin": result = stop_launch_agent() elif self.os_family == "Linux": - if "WSL2" in platform.platform(): - stop_service() - else: - print("Not Implemented") + stop_service() elif self.os_family == "Windows": print("Not Implemented") return result @@ -66,10 +57,7 @@ def start(self) -> bool: if self.os_family == "Darwin": result = start_launch_agent() elif self.os_family == "Linux": - if "WSL2" in platform.platform(): - start_service() - else: - print("Not Implemented") + start_service() elif self.os_family == "Windows": print("Not Implemented") return result @@ -78,9 +66,6 @@ def logs(self): if self.os_family == "Darwin": view_launch_agent_logs() elif self.os_family == "Linux": - if "WSL2" in platform.platform(): - view_service_logs() - else: - print("Not Implemented") + view_service_logs() elif self.os_family == "Windows": print("Not Implemented")