Add a few more static profiles

This commit is contained in:
Sergey Abramchuk
2020-06-16 12:59:00 +03:00
parent 54458439c3
commit f2d598f646
+25 -1
View File
@@ -18,6 +18,18 @@ struct VPNProfile {
} }
extension VPNProfile { extension VPNProfile {
///
static let general: VPNProfile = {
let configuration: String = <#OPENVPN_CONFIGURATION#>
let username: String? = <#OPENVPN_USERNAME#>
let password: String? = <#OPENVPN_PASSWORD#>
let settings: [String: String]? = <#OPENVPN_ADDITIONAL_SETTINGS#>
return VPNProfile(configuration: configuration, username: username, password: password, settings: settings)
}()
/// ///
static let caOnly: VPNProfile = { static let caOnly: VPNProfile = {
let configuration: String = <#OPENVPN_CONFIGURATION#> let configuration: String = <#OPENVPN_CONFIGURATION#>
@@ -26,7 +38,7 @@ extension VPNProfile {
let password: String? = <#OPENVPN_PASSWORD#> let password: String? = <#OPENVPN_PASSWORD#>
let settings: [String: String]? = <#OPENVPN_ADDITIONAL_SETTINGS#> let settings: [String: String]? = <#OPENVPN_ADDITIONAL_SETTINGS#>
return VPNProfile(configuration: configuration, username: username, password: password, settings: settings) return VPNProfile(configuration: configuration, username: username, password: password, settings: settings)
}() }()
@@ -41,4 +53,16 @@ extension VPNProfile {
return VPNProfile(configuration: configuration, username: username, password: password, settings: settings) return VPNProfile(configuration: configuration, username: username, password: password, settings: settings)
}() }()
///
static let withoutCredentials: VPNProfile = {
let configuration: String = <#OPENVPN_CONFIGURATION#>
let username: String? = <#OPENVPN_USERNAME#>
let password: String? = <#OPENVPN_PASSWORD#>
let settings: [String: String]? = <#OPENVPN_ADDITIONAL_SETTINGS#>
return VPNProfile(configuration: configuration, username: username, password: password, settings: settings)
}()
} }