mirror of
https://github.com/lordmathis/llamactl.git
synced 2025-11-05 16:44:22 +00:00
Remove instance restart from update handler
This commit is contained in:
@@ -213,12 +213,6 @@ func (h *Handler) UpdateInstance() http.HandlerFunc {
|
||||
return
|
||||
}
|
||||
|
||||
instance, err = h.InstanceManager.RestartInstance(name)
|
||||
if err != nil {
|
||||
http.Error(w, "Failed to restart instance: "+err.Error(), http.StatusInternalServerError)
|
||||
return
|
||||
}
|
||||
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
if err := json.NewEncoder(w).Encode(instance); err != nil {
|
||||
http.Error(w, "Failed to encode instance: "+err.Error(), http.StatusInternalServerError)
|
||||
|
||||
@@ -3,16 +3,16 @@ import { CreateInstanceOptions, Instance } from "@/types/instance"
|
||||
const API_BASE = '/api/v1'
|
||||
|
||||
// Configuration for API calls
|
||||
interface ApiConfig {
|
||||
apiKey?: string
|
||||
}
|
||||
// interface ApiConfig {
|
||||
// apiKey?: string
|
||||
// }
|
||||
|
||||
// Global config - can be updated when auth is added
|
||||
let apiConfig: ApiConfig = {}
|
||||
// let apiConfig: ApiConfig = {}
|
||||
|
||||
export const setApiConfig = (config: ApiConfig) => {
|
||||
apiConfig = config
|
||||
}
|
||||
// export const setApiConfig = (config: ApiConfig) => {
|
||||
// apiConfig = config
|
||||
// }
|
||||
|
||||
// Base API call function with error handling
|
||||
async function apiCall<T>(
|
||||
|
||||
Reference in New Issue
Block a user