feat(backends): install from local path (#5962)

Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
This commit is contained in:
Ettore Di Giacinto authored and GitHub committed 2025-08-03 14:24:50 +02:00
1 parent 3d8ec72dbf
commit a35a701052
5 files changed
+43 -66

No files matched your search

+5
View File
@@ -144,6 +144,11 @@ func (u URI) LooksLikeHTTPURL() bool {
strings.HasPrefix(string(u), HTTPSPrefix)
}
func (u URI) LooksLikeDir() bool {
f, err := os.Stat(string(u))
return err == nil && f.IsDir()
}
func (s URI) LooksLikeOCI() bool {
return strings.HasPrefix(string(s), "quay.io") ||
strings.HasPrefix(string(s), OCIPrefix) ||