installer v1 (C+D): Windows EXE installer trio + build script + local Hub E2E

This commit is contained in:
gti
2026-09-23 17:44:48 -03:00
parent 91c4030b06
commit a9aded1e49
19 changed files with 792 additions and 16 deletions
+24
View File
@@ -0,0 +1,24 @@
"""GTIFiscalAgentService.exe — frozen Windows Service host.
A thin entry that hands control to the already-bundled
`gti_agent_windows_service` wrapper (which reuses run_agent_service.run()).
It only guarantees the service locates `agent.env` and the DPAPI credential in
the install directory used by Setup.exe, regardless of how SCM launches it.
Built as a PyInstaller onedir; Setup.exe extracts this binary + its
`_internal/` dir into C:\Program Files\GTI\FiscalAgent\.
"""
from __future__ import annotations
import os
import sys
from pathlib import Path
INSTALL_DIR = Path(os.environ.get("PROGRAMFILES", r"C:\Program Files")) / "GTI" / "FiscalAgent"
os.environ.setdefault("GTI_AGENT_ENV_FILE", str(INSTALL_DIR / "agent.env"))
from gti_agent_windows_service import main # noqa: E402 (bundled by PyInstaller)
if __name__ == "__main__":
sys.exit(main())