alicloud.vpc.getIpsecServers
Explore with Pulumi AI
This data source provides the Vpn Ipsec Servers of the current Alibaba Cloud user.
NOTE: Available in v1.161.0+.
Example Usage
Basic Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Vpc.GetIpsecServers.Invoke(new()
{
Ids = new[]
{
"example_id",
},
});
var nameRegex = AliCloud.Vpc.GetIpsecServers.Invoke(new()
{
NameRegex = "^my-IpsecServer",
});
return new Dictionary<string, object?>
{
["vpnIpsecServerId1"] = ids.Apply(getIpsecServersResult => getIpsecServersResult.Servers[0]?.Id),
["vpnIpsecServerId2"] = nameRegex.Apply(getIpsecServersResult => getIpsecServersResult.Servers[0]?.Id),
};
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := vpc.GetIpsecServers(ctx, &vpc.GetIpsecServersArgs{
Ids: []string{
"example_id",
},
}, nil)
if err != nil {
return err
}
ctx.Export("vpnIpsecServerId1", ids.Servers[0].Id)
nameRegex, err := vpc.GetIpsecServers(ctx, &vpc.GetIpsecServersArgs{
NameRegex: pulumi.StringRef("^my-IpsecServer"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpnIpsecServerId2", nameRegex.Servers[0].Id)
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.vpc.VpcFunctions;
import com.pulumi.alicloud.vpc.inputs.GetIpsecServersArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var ids = VpcFunctions.getIpsecServers(GetIpsecServersArgs.builder()
.ids("example_id")
.build());
ctx.export("vpnIpsecServerId1", ids.applyValue(getIpsecServersResult -> getIpsecServersResult.servers()[0].id()));
final var nameRegex = VpcFunctions.getIpsecServers(GetIpsecServersArgs.builder()
.nameRegex("^my-IpsecServer")
.build());
ctx.export("vpnIpsecServerId2", nameRegex.applyValue(getIpsecServersResult -> getIpsecServersResult.servers()[0].id()));
}
}
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.vpc.get_ipsec_servers(ids=["example_id"])
pulumi.export("vpnIpsecServerId1", ids.servers[0].id)
name_regex = alicloud.vpc.get_ipsec_servers(name_regex="^my-IpsecServer")
pulumi.export("vpnIpsecServerId2", name_regex.servers[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.vpc.getIpsecServers({
ids: ["example_id"],
});
export const vpnIpsecServerId1 = ids.then(ids => ids.servers?.[0]?.id);
const nameRegex = alicloud.vpc.getIpsecServers({
nameRegex: "^my-IpsecServer",
});
export const vpnIpsecServerId2 = nameRegex.then(nameRegex => nameRegex.servers?.[0]?.id);
variables:
ids:
fn::invoke:
Function: alicloud:vpc:getIpsecServers
Arguments:
ids:
- example_id
nameRegex:
fn::invoke:
Function: alicloud:vpc:getIpsecServers
Arguments:
nameRegex: ^my-IpsecServer
outputs:
vpnIpsecServerId1: ${ids.servers[0].id}
vpnIpsecServerId2: ${nameRegex.servers[0].id}
Using getIpsecServers
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getIpsecServers(args: GetIpsecServersArgs, opts?: InvokeOptions): Promise<GetIpsecServersResult>
function getIpsecServersOutput(args: GetIpsecServersOutputArgs, opts?: InvokeOptions): Output<GetIpsecServersResult>
def get_ipsec_servers(ids: Optional[Sequence[str]] = None,
ipsec_server_name: Optional[str] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
vpn_gateway_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetIpsecServersResult
def get_ipsec_servers_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
ipsec_server_name: Optional[pulumi.Input[str]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
vpn_gateway_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetIpsecServersResult]
func GetIpsecServers(ctx *Context, args *GetIpsecServersArgs, opts ...InvokeOption) (*GetIpsecServersResult, error)
func GetIpsecServersOutput(ctx *Context, args *GetIpsecServersOutputArgs, opts ...InvokeOption) GetIpsecServersResultOutput
> Note: This function is named GetIpsecServers
in the Go SDK.
public static class GetIpsecServers
{
public static Task<GetIpsecServersResult> InvokeAsync(GetIpsecServersArgs args, InvokeOptions? opts = null)
public static Output<GetIpsecServersResult> Invoke(GetIpsecServersInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetIpsecServersResult> getIpsecServers(GetIpsecServersArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:vpc/getIpsecServers:getIpsecServers
arguments:
# arguments dictionary
The following arguments are supported:
- Ids List<string>
A list of Ipsec Server IDs.
- Ipsec
Server stringName The name of the IPsec server.
- Name
Regex string A regex string to filter results by Ipsec Server name.
- Output
File string File name where to save data source results (after running
pulumi preview
).- Vpn
Gateway stringId The ID of the VPN gateway.
- Ids []string
A list of Ipsec Server IDs.
- Ipsec
Server stringName The name of the IPsec server.
- Name
Regex string A regex string to filter results by Ipsec Server name.
- Output
File string File name where to save data source results (after running
pulumi preview
).- Vpn
Gateway stringId The ID of the VPN gateway.
- ids List<String>
A list of Ipsec Server IDs.
- ipsec
Server StringName The name of the IPsec server.
- name
Regex String A regex string to filter results by Ipsec Server name.
- output
File String File name where to save data source results (after running
pulumi preview
).- vpn
Gateway StringId The ID of the VPN gateway.
- ids string[]
A list of Ipsec Server IDs.
- ipsec
Server stringName The name of the IPsec server.
- name
Regex string A regex string to filter results by Ipsec Server name.
- output
File string File name where to save data source results (after running
pulumi preview
).- vpn
Gateway stringId The ID of the VPN gateway.
- ids Sequence[str]
A list of Ipsec Server IDs.
- ipsec_
server_ strname The name of the IPsec server.
- name_
regex str A regex string to filter results by Ipsec Server name.
- output_
file str File name where to save data source results (after running
pulumi preview
).- vpn_
gateway_ strid The ID of the VPN gateway.
- ids List<String>
A list of Ipsec Server IDs.
- ipsec
Server StringName The name of the IPsec server.
- name
Regex String A regex string to filter results by Ipsec Server name.
- output
File String File name where to save data source results (after running
pulumi preview
).- vpn
Gateway StringId The ID of the VPN gateway.
getIpsecServers Result
The following output properties are available:
- Id string
The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- Servers
List<Pulumi.
Ali Cloud. Vpc. Outputs. Get Ipsec Servers Server> - Ipsec
Server stringName - Name
Regex string - Output
File string - Vpn
Gateway stringId
- Id string
The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- Servers
[]Get
Ipsec Servers Server - Ipsec
Server stringName - Name
Regex string - Output
File string - Vpn
Gateway stringId
- id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- servers
List<Get
Ipsec Servers Server> - ipsec
Server StringName - name
Regex String - output
File String - vpn
Gateway StringId
- id string
The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- servers
Get
Ipsec Servers Server[] - ipsec
Server stringName - name
Regex string - output
File string - vpn
Gateway stringId
- id str
The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- servers
Sequence[Get
Ipsec Servers Server] - ipsec_
server_ strname - name_
regex str - output_
file str - vpn_
gateway_ strid
- id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- servers List<Property Map>
- ipsec
Server StringName - name
Regex String - output
File String - vpn
Gateway StringId
Supporting Types
GetIpsecServersServer
- Client
Ip stringPool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- Create
Time string The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- Effect
Immediately bool Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- Id string
The ID of the Ipsec Server.
- Idaas
Instance stringId The ID of the Identity as a Service (IDaaS) instance.
- Ike
Configs List<Pulumi.Ali Cloud. Vpc. Inputs. Get Ipsec Servers Server Ike Config> The configurations of Phase 1 negotiations.
- Internet
Ip string The public IP address of the VPN gateway.
- Ipsec
Configs List<Pulumi.Ali Cloud. Vpc. Inputs. Get Ipsec Servers Server Ipsec Config> The configuration of Phase 2 negotiations.
- Ipsec
Server stringId The ID of the IPsec server.
- Ipsec
Server stringName The name of the IPsec server.
- Local
Subnet string Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- Max
Connections int The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- Multi
Factor boolAuth Enabled Whether the two-factor authentication function has been turned on.
- Online
Client intCount The number of clients that have connected to the IPsec server.
- Psk string
The pre-shared key.
- Psk
Enabled bool Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- Vpn
Gateway stringId The ID of the VPN gateway.
- Client
Ip stringPool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- Create
Time string The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- Effect
Immediately bool Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- Id string
The ID of the Ipsec Server.
- Idaas
Instance stringId The ID of the Identity as a Service (IDaaS) instance.
- Ike
Configs []GetIpsec Servers Server Ike Config The configurations of Phase 1 negotiations.
- Internet
Ip string The public IP address of the VPN gateway.
- Ipsec
Configs []GetIpsec Servers Server Ipsec Config The configuration of Phase 2 negotiations.
- Ipsec
Server stringId The ID of the IPsec server.
- Ipsec
Server stringName The name of the IPsec server.
- Local
Subnet string Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- Max
Connections int The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- Multi
Factor boolAuth Enabled Whether the two-factor authentication function has been turned on.
- Online
Client intCount The number of clients that have connected to the IPsec server.
- Psk string
The pre-shared key.
- Psk
Enabled bool Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- Vpn
Gateway stringId The ID of the VPN gateway.
- client
Ip StringPool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- create
Time String The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- effect
Immediately Boolean Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- id String
The ID of the Ipsec Server.
- idaas
Instance StringId The ID of the Identity as a Service (IDaaS) instance.
- ike
Configs List<GetIpsec Servers Server Ike Config> The configurations of Phase 1 negotiations.
- internet
Ip String The public IP address of the VPN gateway.
- ipsec
Configs List<GetIpsec Servers Server Ipsec Config> The configuration of Phase 2 negotiations.
- ipsec
Server StringId The ID of the IPsec server.
- ipsec
Server StringName The name of the IPsec server.
- local
Subnet String Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- max
Connections Integer The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- multi
Factor BooleanAuth Enabled Whether the two-factor authentication function has been turned on.
- online
Client IntegerCount The number of clients that have connected to the IPsec server.
- psk String
The pre-shared key.
- psk
Enabled Boolean Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- vpn
Gateway StringId The ID of the VPN gateway.
- client
Ip stringPool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- create
Time string The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- effect
Immediately boolean Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- id string
The ID of the Ipsec Server.
- idaas
Instance stringId The ID of the Identity as a Service (IDaaS) instance.
- ike
Configs GetIpsec Servers Server Ike Config[] The configurations of Phase 1 negotiations.
- internet
Ip string The public IP address of the VPN gateway.
- ipsec
Configs GetIpsec Servers Server Ipsec Config[] The configuration of Phase 2 negotiations.
- ipsec
Server stringId The ID of the IPsec server.
- ipsec
Server stringName The name of the IPsec server.
- local
Subnet string Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- max
Connections number The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- multi
Factor booleanAuth Enabled Whether the two-factor authentication function has been turned on.
- online
Client numberCount The number of clients that have connected to the IPsec server.
- psk string
The pre-shared key.
- psk
Enabled boolean Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- vpn
Gateway stringId The ID of the VPN gateway.
- client_
ip_ strpool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- create_
time str The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- effect_
immediately bool Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- id str
The ID of the Ipsec Server.
- idaas_
instance_ strid The ID of the Identity as a Service (IDaaS) instance.
- ike_
configs Sequence[GetIpsec Servers Server Ike Config] The configurations of Phase 1 negotiations.
- internet_
ip str The public IP address of the VPN gateway.
- ipsec_
configs Sequence[GetIpsec Servers Server Ipsec Config] The configuration of Phase 2 negotiations.
- ipsec_
server_ strid The ID of the IPsec server.
- ipsec_
server_ strname The name of the IPsec server.
- local_
subnet str Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- max_
connections int The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- multi_
factor_ boolauth_ enabled Whether the two-factor authentication function has been turned on.
- online_
client_ intcount The number of clients that have connected to the IPsec server.
- psk str
The pre-shared key.
- psk_
enabled bool Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- vpn_
gateway_ strid The ID of the VPN gateway.
- client
Ip StringPool The CIDR block of the client, which is assigned an access address to the virtual NIC of the client.
- create
Time String The creation time of the IPsec server. T represents the delimiter, and Z represents UTC, which is World Standard Time.
- effect
Immediately Boolean Indicates whether the current IPsec tunnel is deleted and negotiations are reinitiated.
- id String
The ID of the Ipsec Server.
- idaas
Instance StringId The ID of the Identity as a Service (IDaaS) instance.
- ike
Configs List<Property Map> The configurations of Phase 1 negotiations.
- internet
Ip String The public IP address of the VPN gateway.
- ipsec
Configs List<Property Map> The configuration of Phase 2 negotiations.
- ipsec
Server StringId The ID of the IPsec server.
- ipsec
Server StringName The name of the IPsec server.
- local
Subnet String Local network segment: the network segment on The VPC side that needs to be interconnected with the client network segment.
- max
Connections Number The number of SSL connections of the VPN gateway. SSL-VPN the number of SSL connections shared with the IPsec server. For example, if the number of SSL connections is 5 and you have three SSL clients connected to the SSL-VPN, you can also use two clients to connect to the IPsec server.
- multi
Factor BooleanAuth Enabled Whether the two-factor authentication function has been turned on.
- online
Client NumberCount The number of clients that have connected to the IPsec server.
- psk String
The pre-shared key.
- psk
Enabled Boolean Whether to enable the pre-shared key authentication method. The value is only
true
, which indicates that the pre-shared key authentication method is enabled.- vpn
Gateway StringId The ID of the VPN gateway.
GetIpsecServersServerIkeConfig
- Ike
Auth stringAlg The IKE authentication algorithm.
- Ike
Enc stringAlg The IKE encryption algorithm.
- Ike
Lifetime int The IKE lifetime. Unit: seconds.
- Ike
Mode string The IKE negotiation mode.
- Ike
Pfs string Diffie-Hellman key exchange algorithm.
- Ike
Version string The IKE version.
- Local
Id string IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- Remote
Id string The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
- Ike
Auth stringAlg The IKE authentication algorithm.
- Ike
Enc stringAlg The IKE encryption algorithm.
- Ike
Lifetime int The IKE lifetime. Unit: seconds.
- Ike
Mode string The IKE negotiation mode.
- Ike
Pfs string Diffie-Hellman key exchange algorithm.
- Ike
Version string The IKE version.
- Local
Id string IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- Remote
Id string The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
- ike
Auth StringAlg The IKE authentication algorithm.
- ike
Enc StringAlg The IKE encryption algorithm.
- ike
Lifetime Integer The IKE lifetime. Unit: seconds.
- ike
Mode String The IKE negotiation mode.
- ike
Pfs String Diffie-Hellman key exchange algorithm.
- ike
Version String The IKE version.
- local
Id String IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- remote
Id String The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
- ike
Auth stringAlg The IKE authentication algorithm.
- ike
Enc stringAlg The IKE encryption algorithm.
- ike
Lifetime number The IKE lifetime. Unit: seconds.
- ike
Mode string The IKE negotiation mode.
- ike
Pfs string Diffie-Hellman key exchange algorithm.
- ike
Version string The IKE version.
- local
Id string IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- remote
Id string The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
- ike_
auth_ stralg The IKE authentication algorithm.
- ike_
enc_ stralg The IKE encryption algorithm.
- ike_
lifetime int The IKE lifetime. Unit: seconds.
- ike_
mode str The IKE negotiation mode.
- ike_
pfs str Diffie-Hellman key exchange algorithm.
- ike_
version str The IKE version.
- local_
id str IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- remote_
id str The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
- ike
Auth StringAlg The IKE authentication algorithm.
- ike
Enc StringAlg The IKE encryption algorithm.
- ike
Lifetime Number The IKE lifetime. Unit: seconds.
- ike
Mode String The IKE negotiation mode.
- ike
Pfs String Diffie-Hellman key exchange algorithm.
- ike
Version String The IKE version.
- local
Id String IPsec server identifier. Supports the format of FQDN and IP address. The public IP address of the VPN gateway is selected by default.
- remote
Id String The peer identifier. Supports the format of FQDN and IP address, which is empty by default.
GetIpsecServersServerIpsecConfig
- Ipsec
Auth stringAlg IPsec authentication algorithm.
- Ipsec
Enc stringAlg IPsec encryption algorithm.
- Ipsec
Lifetime int IPsec survival time. Unit: seconds.
- Ipsec
Pfs string Diffie-Hellman key exchange algorithm.
- Ipsec
Auth stringAlg IPsec authentication algorithm.
- Ipsec
Enc stringAlg IPsec encryption algorithm.
- Ipsec
Lifetime int IPsec survival time. Unit: seconds.
- Ipsec
Pfs string Diffie-Hellman key exchange algorithm.
- ipsec
Auth StringAlg IPsec authentication algorithm.
- ipsec
Enc StringAlg IPsec encryption algorithm.
- ipsec
Lifetime Integer IPsec survival time. Unit: seconds.
- ipsec
Pfs String Diffie-Hellman key exchange algorithm.
- ipsec
Auth stringAlg IPsec authentication algorithm.
- ipsec
Enc stringAlg IPsec encryption algorithm.
- ipsec
Lifetime number IPsec survival time. Unit: seconds.
- ipsec
Pfs string Diffie-Hellman key exchange algorithm.
- ipsec_
auth_ stralg IPsec authentication algorithm.
- ipsec_
enc_ stralg IPsec encryption algorithm.
- ipsec_
lifetime int IPsec survival time. Unit: seconds.
- ipsec_
pfs str Diffie-Hellman key exchange algorithm.
- ipsec
Auth StringAlg IPsec authentication algorithm.
- ipsec
Enc StringAlg IPsec encryption algorithm.
- ipsec
Lifetime Number IPsec survival time. Unit: seconds.
- ipsec
Pfs String Diffie-Hellman key exchange algorithm.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
alicloud
Terraform Provider.