mirror of
https://github.com/pomerium/pomerium.git
synced 2025-06-01 10:22:43 +02:00
zero: use production urls by default (#4814)
This commit is contained in:
parent
2edd63c58a
commit
d2b2ad3250
3 changed files with 14 additions and 32 deletions
|
@ -29,3 +29,17 @@ func getToken(configFile string) string {
|
|||
// we will fallback to normal pomerium if empty
|
||||
return ""
|
||||
}
|
||||
|
||||
func getConnectAPIEndpoint() string {
|
||||
if endpoint := os.Getenv("CONNECT_SERVER_ENDPOINT"); endpoint != "" {
|
||||
return endpoint
|
||||
}
|
||||
return "https://connect.pomerium.app"
|
||||
}
|
||||
|
||||
func getClusterAPIEndpoint() string {
|
||||
if endpoint := os.Getenv("CLUSTER_API_ENDPOINT"); endpoint != "" {
|
||||
return endpoint
|
||||
}
|
||||
return "https://console.pomerium.app/cluster/v1"
|
||||
}
|
||||
|
|
|
@ -1,21 +0,0 @@
|
|||
//go:build !release
|
||||
|
||||
package cmd
|
||||
|
||||
import "os"
|
||||
|
||||
func getConnectAPIEndpoint() string {
|
||||
connectServerEndpoint := os.Getenv("CONNECT_SERVER_ENDPOINT")
|
||||
if connectServerEndpoint == "" {
|
||||
connectServerEndpoint = "http://localhost:8721"
|
||||
}
|
||||
return connectServerEndpoint
|
||||
}
|
||||
|
||||
func getClusterAPIEndpoint() string {
|
||||
clusterAPIEndpoint := os.Getenv("CLUSTER_API_ENDPOINT")
|
||||
if clusterAPIEndpoint == "" {
|
||||
clusterAPIEndpoint = "http://localhost:8720/cluster/v1"
|
||||
}
|
||||
return clusterAPIEndpoint
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
//go:build release
|
||||
|
||||
package cmd
|
||||
|
||||
func getConnectAPIEndpoint() string {
|
||||
return "https://connect.pomerium.app"
|
||||
}
|
||||
|
||||
func getClusterAPIEndpoint() string {
|
||||
return "https://console.pomerium.app/cluster/v1"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue