feat(systemd-manager): Support sudo password and root detection in SystemdManager; add user/group support in services and templates; add tests and expand README

This commit is contained in:
2025-09-03 11:16:45 +00:00
parent 0ae3b9a5ec
commit 972688b8be
9 changed files with 552 additions and 78 deletions

View File

@@ -1,5 +1,17 @@
# Changelog
## 2025-09-03 - 2.1.0 - feat(systemd-manager)
Support sudo password and root detection in SystemdManager; add user/group support in services and templates; add tests and expand README
- SystemdManager now accepts an optional sudoPassword and detects root status on startup
- Commands executed via SystemdManager are automatically prefixed with sudo when not running as root; supports interactive PTY flow to provide sudo password
- saveService/deleteService now use direct writes when running as root and fallback to sudo-based moves/removals when not root
- Service model extended with optional user and group properties
- Template manager updated to include user/group comments and to emit User/Group directives in generated systemd unit files when provided
- Exports updated (ts/index.ts) to include SmartDaemonService
- New/updated tests added to verify root detection, service creation, unit file generation and sudoPassword option
- README expanded with detailed usage examples, API docs and troubleshooting/security guidance
## 2025-08-29 - 2.0.9 - fix(tests)
update test runner and developer dependencies; add pnpm workspace and packageManager