Skip to content

Commit 152c333

Browse files
Allow overriding the render host destination with an env var (#27)
This allows us to test the mcp server against staging or a development cluster GitOrigin-RevId: a42ab14
1 parent aa9eff3 commit 152c333

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

pkg/cfg/cfg.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ var Version = "dev"
1010
var osInfo string
1111

1212
func GetHost() string {
13-
return "https://api.render.com/v1/"
13+
baseHost := "api.render.com"
14+
if host := os.Getenv("RENDER_HOST"); host != "" {
15+
baseHost = host
16+
}
17+
return fmt.Sprintf("https://%s/v1", baseHost)
1418
}
1519

1620
func GetAPIKey() string {

0 commit comments

Comments
 (0)