wip: oci image management
This commit is contained in:
14
controller/registry.go
Normal file
14
controller/registry.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package controller
|
||||
|
||||
import (
|
||||
"gitea.loveuer.com/loveuer/cluster/internal/database"
|
||||
)
|
||||
|
||||
// ListImages 返回所有仓库列表
|
||||
func ListImages() ([]database.Repository, error) {
|
||||
var repos []database.Repository
|
||||
if err := database.DB.Find(&repos).Error; err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return repos, nil
|
||||
}
|
||||
Reference in New Issue
Block a user