Change: Use SERVER_HOSTNAME instead of HOSTNAME

This commit is contained in:
Quentin McGaw
2020-12-31 21:50:28 +00:00
parent 02cde5f50b
commit d713782fe1
3 changed files with 11 additions and 5 deletions

View File

@@ -2,10 +2,13 @@ package params
import (
"github.com/qdm12/gluetun/internal/constants"
libparams "github.com/qdm12/golibs/params"
)
// GetPrivadoHostnames obtains the hostnames for the Privado server from the
// environment variable HOSTNAME.
// environment variable SERVER_HOSTNAME.
func (r *reader) GetPrivadoHostnames() (hosts []string, err error) {
return r.envParams.GetCSVInPossibilities("HOSTNAME", constants.PrivadoHostnameChoices())
return r.envParams.GetCSVInPossibilities("SERVER_HOSTNAME",
constants.PrivadoHostnameChoices(),
libparams.RetroKeys([]string{"HOSTNAME"}, r.onRetroActive))
}