Files
vendoo/app/modules/module-manager/index.mjs
T
Masterluke77andGitHub 6f48827f4d Vendoo 1.41.2 – Git Ignore Boundary & Module Tracking Hotfix (#18)
* docs: prepare Vendoo 1.41.2 git-ignore boundary hotfix

* fix: track native source modules with root-anchored runtime ignores
2026-07-09 17:09:00 +02:00

29 lines
769 B
JavaScript

import manifest from './module.json' with { type: 'json' };
import { ModuleManagerService } from './service.mjs';
let service = null;
export function createModuleManagerModule() {
return {
manifest,
source: 'builtin',
lifecycle: {
async start(context) {
service = new ModuleManagerService({
modules: context.modules,
stateStore: context.moduleStateStore,
packageStore: context.modulePackageStore,
context,
});
},
async stop() { service = null; },
async health() { return { ok: Boolean(service), protected: true }; },
},
};
}
export function getModuleManagerService() {
if (!service) throw new Error('Module Manager ist noch nicht gestartet.');
return service;
}