Don't strip remote llama-cpp proxy prefix

This commit is contained in:
2025-10-25 16:02:09 +02:00
parent 889df3cb79
commit 7d9b983f93

View File

@@ -88,9 +88,11 @@ func (h *Handler) LlamaCppProxy(onDemandStart bool) http.HandlerFunc {
return return
} }
if !inst.IsRemote() {
// Strip the "/llama-cpp/<name>" prefix from the request URL // Strip the "/llama-cpp/<name>" prefix from the request URL
prefix := fmt.Sprintf("/llama-cpp/%s", validatedName) prefix := fmt.Sprintf("/llama-cpp/%s", validatedName)
r.URL.Path = strings.TrimPrefix(r.URL.Path, prefix) r.URL.Path = strings.TrimPrefix(r.URL.Path, prefix)
}
// Update the last request time for the instance // Update the last request time for the instance
inst.UpdateLastRequestTime() inst.UpdateLastRequestTime()