1
0
mirror of https://github.com/0O0o0oOoO00/Alas.git synced 2026-05-14 16:09:25 +08:00

fix: try to add alas instance itself to watcher when start

This commit is contained in:
0O0o0oOoO00
2025-09-15 17:31:15 +08:00
parent 394ac8bd04
commit 5e4e00eacb
2 changed files with 15 additions and 13 deletions

View File

@@ -231,3 +231,16 @@ class ProcessManager:
except:
pass
logger.info("Start alas complete")
from module.instance_watcher import InstanceWatcher
class ProcessManager(ProcessManager):
def start(self, *args, **kwargs):
super().start(*args, **kwargs)
InstanceWatcher.get_instance().try_add_instance(self.config_name)
def stop(self, *args, **kwargs):
InstanceWatcher.get_instance().remove_instance(self.config_name)
super().stop(*args, **kwargs)