OVH v0.2.0, Feb 19 23
OVH v0.2.0, Feb 19 23
ovh.Me.getSshKey
Use this data source to retrieve information about an SSH key.
Example Usage
using System.Collections.Generic;
using Pulumi;
using Ovh = Pulumi.Ovh;
return await Deployment.RunAsync(() =>
{
var mykey = Ovh.Me.GetSshKey.Invoke(new()
{
KeyName = "mykey",
});
});
package main
import (
"github.com/lbrlabs/pulumi-ovh/sdk/go/ovh/Me"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := Me.GetSshKey(ctx, &me.GetSshKeyArgs{
KeyName: "mykey",
}, nil)
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ovh.Me.MeFunctions;
import com.pulumi.ovh.Me.inputs.GetSshKeyArgs;
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 mykey = MeFunctions.getSshKey(GetSshKeyArgs.builder()
.keyName("mykey")
.build());
}
}
import pulumi
import pulumi_ovh as ovh
mykey = ovh.Me.get_ssh_key(key_name="mykey")
import * as pulumi from "@pulumi/pulumi";
import * as ovh from "@pulumi/ovh";
const mykey = ovh.Me.getSshKey({
keyName: "mykey",
});
variables:
mykey:
fn::invoke:
Function: ovh:Me:getSshKey
Arguments:
keyName: mykey
Using getSshKey
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 getSshKey(args: GetSshKeyArgs, opts?: InvokeOptions): Promise<GetSshKeyResult>
function getSshKeyOutput(args: GetSshKeyOutputArgs, opts?: InvokeOptions): Output<GetSshKeyResult>
def get_ssh_key(key_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetSshKeyResult
def get_ssh_key_output(key_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSshKeyResult]
func GetSshKey(ctx *Context, args *GetSshKeyArgs, opts ...InvokeOption) (*GetSshKeyResult, error)
func GetSshKeyOutput(ctx *Context, args *GetSshKeyOutputArgs, opts ...InvokeOption) GetSshKeyResultOutput
> Note: This function is named GetSshKey
in the Go SDK.
public static class GetSshKey
{
public static Task<GetSshKeyResult> InvokeAsync(GetSshKeyArgs args, InvokeOptions? opts = null)
public static Output<GetSshKeyResult> Invoke(GetSshKeyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSshKeyResult> getSshKey(GetSshKeyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: ovh:Me/getSshKey:getSshKey
arguments:
# arguments dictionary
The following arguments are supported:
- Key
Name string The name of the SSH key.
- Key
Name string The name of the SSH key.
- key
Name String The name of the SSH key.
- key
Name string The name of the SSH key.
- key_
name str The name of the SSH key.
- key
Name String The name of the SSH key.
getSshKey Result
The following output properties are available:
Package Details
- Repository
- ovh lbrlabs/pulumi-ovh
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
ovh
Terraform Provider.