feat(sol): UDP + HTTP listener

This commit is contained in:
Björn Benouarets
2025-11-11 17:19:49 +01:00
commit 8ed56f7ba0
12 changed files with 565 additions and 0 deletions

18
system/shutdown.go Normal file
View File

@@ -0,0 +1,18 @@
//go:build !windows
// +build !windows
package system
import (
"log"
"os/exec"
)
// Shutdown shuts down the system (Unix/Linux/macOS)
func Shutdown() {
cmd := exec.Command("shutdown", "-h", "now")
if err := cmd.Run(); err != nil {
log.Fatalf("Failed to shutdown system: %v", err)
}
}