feat: dynamically set swagger host, and some ui improvements on ssh page

This commit is contained in:
allanice001
2025-11-06 05:52:06 +00:00
parent 7dc7d1a1f1
commit 12f2c5e1c5
4 changed files with 40 additions and 29 deletions

11
main.go
View File

@@ -1,6 +1,12 @@
package main
import "github.com/glueops/autoglue/cmd"
import (
"os"
"github.com/glueops/autoglue/cmd"
"github.com/glueops/autoglue/docs"
"github.com/joho/godotenv"
)
// @title AutoGlue API
// @version 1.0
@@ -10,7 +16,6 @@ import "github.com/glueops/autoglue/cmd"
// @BasePath /api/v1
// @schemes http https
// @host localhost:8080
// @securityDefinitions.apikey BearerAuth
// @in header
@@ -33,5 +38,7 @@ import "github.com/glueops/autoglue/cmd"
// @description Org-level secret
func main() {
_ = godotenv.Load()
docs.SwaggerInfo.Host = os.Getenv("SWAGGER_HOST")
cmd.Execute()
}