s3 api: get publish root list

This commit is contained in:
André Roth committed 2024-04-03 10:14:01 +02:00
1 parent a0af6a25aa
commit b5b0a52cbe
2 files changed
+18

No files matched your search

+14
View File
@@ -0,0 +1,14 @@
package api
import (
"github.com/gin-gonic/gin"
)
// GET /api/s3
func apiS3List(c *gin.Context) {
keys := []string{}
for k := range context.Config().S3PublishRoots {
keys = append(keys, k)
}
c.JSON(200, keys)
}