2021-02-19 23:33:57 -05:00
|
|
|
package proxy
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"github.com/dokku/dokku/plugins/config"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func getAppProxyType(appName string) string {
|
2024-01-19 04:13:55 -05:00
|
|
|
return config.GetWithDefault(appName, "DOKKU_APP_PROXY_TYPE", "")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func getComputedProxyType(appName string) string {
|
2024-01-19 07:15:36 -05:00
|
|
|
proxyType := getAppProxyType(appName)
|
2024-01-19 04:13:55 -05:00
|
|
|
if proxyType == "" {
|
2024-01-19 07:15:36 -05:00
|
|
|
proxyType = getGlobalProxyType()
|
2024-01-19 04:13:55 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return proxyType
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func getGlobalProxyType() string {
|
|
|
|
|
return config.GetWithDefault("--global", "DOKKU_PROXY_TYPE", "nginx")
|
2021-02-19 23:33:57 -05:00
|
|
|
}
|