Maint: refactor VPN configuration structure
- Paves the way for Wireguard - VPN struct contains Type, Openvpn and Provider configurations - OpenVPN specific options (e.g. client key) moved from Provider to Openvpn configuration struct - Move Provider configuration from OpenVPN configuration to VPN - HTTP control server returns only openvpn settings (not provider settings)
This commit is contained in:
@@ -16,21 +16,25 @@ func Test_Settings_lines(t *testing.T) {
|
||||
}{
|
||||
"default settings": {
|
||||
settings: Settings{
|
||||
OpenVPN: OpenVPN{
|
||||
Version: constants.Openvpn25,
|
||||
VPN: VPN{
|
||||
Type: constants.OpenVPN,
|
||||
Provider: Provider{
|
||||
Name: constants.Mullvad,
|
||||
},
|
||||
OpenVPN: OpenVPN{
|
||||
Version: constants.Openvpn25,
|
||||
},
|
||||
},
|
||||
},
|
||||
lines: []string{
|
||||
"Settings summary below:",
|
||||
"|--OpenVPN:",
|
||||
" |--Version: 2.5",
|
||||
" |--Verbosity level: 0",
|
||||
" |--Provider:",
|
||||
" |--Mullvad settings:",
|
||||
" |--Network protocol: udp",
|
||||
"|--VPN:",
|
||||
" |--Type: openvpn",
|
||||
" |--OpenVPN:",
|
||||
" |--Version: 2.5",
|
||||
" |--Verbosity level: 0",
|
||||
" |--Mullvad settings:",
|
||||
" |--Network protocol: udp",
|
||||
"|--DNS:",
|
||||
"|--Firewall: disabled ⚠️",
|
||||
"|--System:",
|
||||
|
||||
Reference in New Issue
Block a user