diff --git a/server/cmd/llamactl.go b/server/cmd/llamactl.go index 36171e7..6d85de6 100644 --- a/server/cmd/llamactl.go +++ b/server/cmd/llamactl.go @@ -4,6 +4,7 @@ import ( "fmt" llamactl "llamactl/pkg" "net/http" + "os" ) // @title llamactl API @@ -20,6 +21,13 @@ func main() { fmt.Println("Using default configuration.") } + // Crate the log directory if it doesn't exist + err = os.MkdirAll(config.Instances.LogDirectory, 0755) + if err != nil { + fmt.Printf("Error creating log directory: %v\n", err) + return + } + // Initialize the instance manager instanceManager := llamactl.NewInstanceManager(config.Instances)