ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud
ionoscloud.getVpnWireguardPeer
Explore with Pulumi AI
ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud
The ionoscloud.VpnWireguardGateway
data source provides information about a specific IonosCloud VPN WireGuard Gateway. You can use this data source to retrieve details of a WireGuard Gateway for use in other resources and configurations.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ionoscloud from "@pulumi/ionoscloud";
const example = ionoscloud.getVpnWireguardPeer({
location: "de/fra",
gatewayId: "example-gateway",
name: "example-peer",
});
export const vpnWireguardPeerPublicKey = data.vpn_wireguard_peer.example.public_key;
import pulumi
import pulumi_ionoscloud as ionoscloud
example = ionoscloud.get_vpn_wireguard_peer(location="de/fra",
gateway_id="example-gateway",
name="example-peer")
pulumi.export("vpnWireguardPeerPublicKey", data["vpn_wireguard_peer"]["example"]["public_key"])
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ionoscloud/v6/ionoscloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ionoscloud.LookupVpnWireguardPeer(ctx, &ionoscloud.LookupVpnWireguardPeerArgs{
Location: pulumi.StringRef("de/fra"),
GatewayId: "example-gateway",
Name: pulumi.StringRef("example-peer"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpnWireguardPeerPublicKey", data.Vpn_wireguard_peer.Example.Public_key)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ionoscloud = Pulumi.Ionoscloud;
return await Deployment.RunAsync(() =>
{
var example = Ionoscloud.GetVpnWireguardPeer.Invoke(new()
{
Location = "de/fra",
GatewayId = "example-gateway",
Name = "example-peer",
});
return new Dictionary<string, object?>
{
["vpnWireguardPeerPublicKey"] = data.Vpn_wireguard_peer.Example.Public_key,
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ionoscloud.IonoscloudFunctions;
import com.pulumi.ionoscloud.inputs.GetVpnWireguardPeerArgs;
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 example = IonoscloudFunctions.getVpnWireguardPeer(GetVpnWireguardPeerArgs.builder()
.location("de/fra")
.gatewayId("example-gateway")
.name("example-peer")
.build());
ctx.export("vpnWireguardPeerPublicKey", data.vpn_wireguard_peer().example().public_key());
}
}
variables:
example:
fn::invoke:
function: ionoscloud:getVpnWireguardPeer
arguments:
location: de/fra
gatewayId: example-gateway
name: example-peer
outputs:
vpnWireguardPeerPublicKey: ${data.vpn_wireguard_peer.example.public_key}
Using getVpnWireguardPeer
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 getVpnWireguardPeer(args: GetVpnWireguardPeerArgs, opts?: InvokeOptions): Promise<GetVpnWireguardPeerResult>
function getVpnWireguardPeerOutput(args: GetVpnWireguardPeerOutputArgs, opts?: InvokeOptions): Output<GetVpnWireguardPeerResult>
def get_vpn_wireguard_peer(gateway_id: Optional[str] = None,
id: Optional[str] = None,
location: Optional[str] = None,
name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetVpnWireguardPeerResult
def get_vpn_wireguard_peer_output(gateway_id: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
location: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetVpnWireguardPeerResult]
func LookupVpnWireguardPeer(ctx *Context, args *LookupVpnWireguardPeerArgs, opts ...InvokeOption) (*LookupVpnWireguardPeerResult, error)
func LookupVpnWireguardPeerOutput(ctx *Context, args *LookupVpnWireguardPeerOutputArgs, opts ...InvokeOption) LookupVpnWireguardPeerResultOutput
> Note: This function is named LookupVpnWireguardPeer
in the Go SDK.
public static class GetVpnWireguardPeer
{
public static Task<GetVpnWireguardPeerResult> InvokeAsync(GetVpnWireguardPeerArgs args, InvokeOptions? opts = null)
public static Output<GetVpnWireguardPeerResult> Invoke(GetVpnWireguardPeerInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetVpnWireguardPeerResult> getVpnWireguardPeer(GetVpnWireguardPeerArgs args, InvokeOptions options)
public static Output<GetVpnWireguardPeerResult> getVpnWireguardPeer(GetVpnWireguardPeerArgs args, InvokeOptions options)
fn::invoke:
function: ionoscloud:index/getVpnWireguardPeer:getVpnWireguardPeer
arguments:
# arguments dictionary
The following arguments are supported:
- gateway_
id str - [String] The ID of the WireGuard Gateway.
- id str
- [String] The ID of the WireGuard Peer.
- location str
- [String] The location of the WireGuard Gateway.
- name str
- [String] The name of the WireGuard Peer.
getVpnWireguardPeer Result
The following output properties are available:
- Allowed
Ips List<string> - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- Description string
- The description of the WireGuard Peer.
- Endpoints
List<Get
Vpn Wireguard Peer Endpoint> - The endpoint of the WireGuard Peer.
- Gateway
Id string - Id string
- The unique ID of the WireGuard Peer.
- Name string
- The name of the WireGuard Peer.
- Public
Key string - WireGuard public key of the connecting peer.
- Status string
- The current status of the WireGuard Peer.
- Location string
- Allowed
Ips []string - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- Description string
- The description of the WireGuard Peer.
- Endpoints
[]Get
Vpn Wireguard Peer Endpoint - The endpoint of the WireGuard Peer.
- Gateway
Id string - Id string
- The unique ID of the WireGuard Peer.
- Name string
- The name of the WireGuard Peer.
- Public
Key string - WireGuard public key of the connecting peer.
- Status string
- The current status of the WireGuard Peer.
- Location string
- allowed
Ips List<String> - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- description String
- The description of the WireGuard Peer.
- endpoints
List<Get
Vpn Wireguard Peer Endpoint> - The endpoint of the WireGuard Peer.
- gateway
Id String - id String
- The unique ID of the WireGuard Peer.
- name String
- The name of the WireGuard Peer.
- public
Key String - WireGuard public key of the connecting peer.
- status String
- The current status of the WireGuard Peer.
- location String
- allowed
Ips string[] - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- description string
- The description of the WireGuard Peer.
- endpoints
Get
Vpn Wireguard Peer Endpoint[] - The endpoint of the WireGuard Peer.
- gateway
Id string - id string
- The unique ID of the WireGuard Peer.
- name string
- The name of the WireGuard Peer.
- public
Key string - WireGuard public key of the connecting peer.
- status string
- The current status of the WireGuard Peer.
- location string
- allowed_
ips Sequence[str] - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- description str
- The description of the WireGuard Peer.
- endpoints
Sequence[Get
Vpn Wireguard Peer Endpoint] - The endpoint of the WireGuard Peer.
- gateway_
id str - id str
- The unique ID of the WireGuard Peer.
- name str
- The name of the WireGuard Peer.
- public_
key str - WireGuard public key of the connecting peer.
- status str
- The current status of the WireGuard Peer.
- location str
- allowed
Ips List<String> - The subnet CIDRs that are allowed to connect to the WireGuard Gateway.
- description String
- The description of the WireGuard Peer.
- endpoints List<Property Map>
- The endpoint of the WireGuard Peer.
- gateway
Id String - id String
- The unique ID of the WireGuard Peer.
- name String
- The name of the WireGuard Peer.
- public
Key String - WireGuard public key of the connecting peer.
- status String
- The current status of the WireGuard Peer.
- location String
Supporting Types
GetVpnWireguardPeerEndpoint
Package Details
- Repository
- ionoscloud ionos-cloud/terraform-provider-ionoscloud
- License
- Notes
- This Pulumi package is based on the
ionoscloud
Terraform Provider.
ionoscloud 6.7.6 published on Monday, Apr 14, 2025 by ionos-cloud