initial commit for JFrog support

This commit is contained in:
Pierig Le Saux
2026-04-07 11:07:27 -04:00
committed by André Roth
parent 8ebe80f066
commit 4b8f0c42ac
9 changed files with 415 additions and 226 deletions
+3
View File
@@ -51,6 +51,9 @@ func createTestConfig() *os.File {
"GcsPublishEndpoints": map[string]map[string]string{
"test-gcs": {
"bucket": "bucket-gcs",
"JFrogPublishEndpoints": gin.H{
"test-jfrog": gin.H{
"url": "http://jfrog.example.com",
},
},
})
+21
View File
@@ -0,0 +1,21 @@
package api
import (
"github.com/gin-gonic/gin"
)
// @Summary JFrog repositories
// @Description **Get list of JFrog repositories**
// @Description
// @Description List configured JFrog publish endpoints.
// @Tags Status
// @Produce json
// @Success 200 {array} string "List of JFrog publish endpoints"
// @Router /api/jfrog [get]
func apiJFrogList(c *gin.Context) {
keys := []string{}
for k := range context.Config().JFrogPublishRoots {
keys = append(keys, k)
}
c.JSON(200, keys)
}
+1
View File
@@ -178,6 +178,7 @@ func Router(c *ctx.AptlyContext) http.Handler {
{
api.GET("/s3", apiS3List)
api.GET("/gcs", apiGCSList)
api.GET("/jfrog", apiJFrogList)
}
{