Change host port to 3001 and add panic recovery to main

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
luskbyte
2026-04-24 23:56:26 -03:00
parent f618d107ed
commit ff3af39973
2 changed files with 10 additions and 3 deletions
+1 -3
View File
@@ -1,10 +1,8 @@
version: '3.8'
services: services:
docker-manager: docker-manager:
build: . build: .
ports: ports:
- "3000:3000" - "3001:3000"
volumes: volumes:
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
environment: environment:
+9
View File
@@ -6,10 +6,19 @@ import (
"fmt" "fmt"
"net/http" "net/http"
"os" "os"
"runtime/debug"
"strings" "strings"
) )
func main() { func main() {
defer func() {
if r := recover(); r != nil {
fmt.Fprintf(os.Stderr, "PANIC: %v\n", r)
debug.PrintStack()
os.Exit(1)
}
}()
// Detect Docker socket // Detect Docker socket
socketPath := docker.DetectSocket() socketPath := docker.DetectSocket()
fmt.Printf("Using Docker socket: %s\n", socketPath) fmt.Printf("Using Docker socket: %s\n", socketPath)