chore(env): bump qdm12/gosettings to v0.3.0-rc11

This commit is contained in:
Quentin McGaw
2023-06-01 08:22:55 +00:00
parent 5d8fbf8006
commit 482447c151
34 changed files with 190 additions and 197 deletions

View File

@@ -7,7 +7,6 @@ import (
"github.com/qdm12/gluetun/internal/configuration/settings"
"github.com/qdm12/gluetun/internal/constants/providers"
"github.com/qdm12/gluetun/internal/constants/vpn"
"github.com/qdm12/gosettings/sources/env"
)
func (s *Source) readProvider(vpnType string) (provider settings.Provider, err error) {
@@ -33,7 +32,7 @@ func (s *Source) readProvider(vpnType string) (provider settings.Provider, err e
func (s *Source) readVPNServiceProvider(vpnType string) (vpnProviderPtr *string) {
_, valuePtr := s.getEnvWithRetro("VPN_SERVICE_PROVIDER", []string{"VPNSP"})
if valuePtr == nil {
if vpnType != vpn.Wireguard && env.Get("OPENVPN_CUSTOM_CONFIG") != nil {
if vpnType != vpn.Wireguard && s.env.Get("OPENVPN_CUSTOM_CONFIG") != nil {
// retro compatibility
return ptrTo(providers.Custom)
}