Change: USER changed to OPENVPN_USER

This commit is contained in:
Quentin McGaw
2020-12-29 20:02:58 +00:00
parent a811a82329
commit d556db079b
4 changed files with 16 additions and 15 deletions

View File

@@ -9,10 +9,11 @@ import (
)
// GetUser obtains the user to use to connect to the VPN servers.
func (r *reader) GetUser() (s string, err error) {
return r.envParams.GetEnv("USER",
func (r *reader) GetUser() (user string, err error) {
return r.envParams.GetEnv("OPENVPN_USER",
libparams.CaseSensitiveValue(),
libparams.Compulsory(),
libparams.RetroKeys([]string{"USER"}, r.onRetroActive),
libparams.Unset())
}