mirror of
https://github.com/R0m1k3/Loki.git
synced 2026-10-22 22:48:11 +02:00
CLI elaguee et tests remis sur la base
- suppression des alias de commandes herites (skills, machine, tools, mem, upgrade...) - aide reecrite et regroupee - helper de test testHome + fermeture de la base (verrou bbolt sous Windows) - tests des dossiers de modeles alignes sur models/
This commit is contained in:
1 parent
6de356f649
commit
62ad4155a2
18 files changed
+202
-153
No files matched your search
@@ -11,7 +11,6 @@ import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
|
||||
const sudoersTemplate = `# Allow %s to manage the %s systemd unit without a password (installed by ajean).
|
||||
%s ALL=(root) NOPASSWD: /bin/systemctl start %s, /bin/systemctl stop %s, /bin/systemctl restart %s, /bin/systemctl enable %s, /bin/systemctl disable %s
|
||||
`
|
||||
@@ -110,7 +109,7 @@ func cmdInstall(args []string) error {
|
||||
}
|
||||
fmt.Printf(" %s /etc/default/ajean\n", green("✓"))
|
||||
|
||||
// 5. Write the systemd unit (ExecStart = `ajean serve`, no start.sh needed)
|
||||
// 4. Write the systemd unit (ExecStart = `ajean serve`, no start.sh needed)
|
||||
unit := fmt.Sprintf(serviceUnitTemplate, targetUser, ajeanHome, installedExePath()+" serve")
|
||||
unitPath := "/etc/systemd/system/" + svc + ".service"
|
||||
if err := os.WriteFile(unitPath, []byte(unit), 0o644); err != nil {
|
||||
|
||||
Reference in new issue
Block a user