Want to learn about running containers in Lambda? Join our free hands-on workshop. Register Now

GetSshKey

linode.SshKey provides access to a specifically labeled SSH Key in the Profile of the User identified by the access token.

Example Usage

using Pulumi;
using Linode = Pulumi.Linode;

class MyStack : Stack
{
    public MyStack()
    {
        var foo = Output.Create(Linode.GetSshKey.InvokeAsync(new Linode.GetSshKeyArgs
        {
            Label = "foo",
        }));
    }

}
package main

import (
    "github.com/pulumi/pulumi-linode/sdk/v2/go/linode"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := linode.LookupSshKey(ctx, &linode.LookupSshKeyArgs{
            Label: "foo",
        }, nil)
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_linode as linode

foo = linode.get_ssh_key(label="foo")
import * as pulumi from "@pulumi/pulumi";
import * as linode from "@pulumi/linode";

const foo = pulumi.output(linode.getSshKey({
    label: "foo",
}, { async: true }));

Using GetSshKey

function getSshKey(args: GetSshKeyArgs, opts?: InvokeOptions): Promise<GetSshKeyResult>
def get_ssh_key(label: Optional[str] = None, opts: Optional[InvokeOptions] = None) -> GetSshKeyResult
func LookupSshKey(ctx *Context, args *LookupSshKeyArgs, opts ...InvokeOption) (*LookupSshKeyResult, error)

Note: This function is named LookupSshKey in the Go SDK.

public static class GetSshKey {
    public static Task<GetSshKeyResult> InvokeAsync(GetSshKeyArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Label string

The label of the SSH Key to select.

Label string

The label of the SSH Key to select.

label string

The label of the SSH Key to select.

label str

The label of the SSH Key to select.

GetSshKey Result

The following output properties are available:

Created string

The date this key was added.

Id string

The provider-assigned unique ID for this managed resource.

Label string
SshKey string

The public SSH Key, which is used to authenticate to the root user of the Linodes you deploy.

Created string

The date this key was added.

Id string

The provider-assigned unique ID for this managed resource.

Label string
SshKey string

The public SSH Key, which is used to authenticate to the root user of the Linodes you deploy.

created string

The date this key was added.

id string

The provider-assigned unique ID for this managed resource.

label string
sshKey string

The public SSH Key, which is used to authenticate to the root user of the Linodes you deploy.

created str

The date this key was added.

id str

The provider-assigned unique ID for this managed resource.

label str
ssh_key str

The public SSH Key, which is used to authenticate to the root user of the Linodes you deploy.

Package Details

Repository
https://github.com/pulumi/pulumi-linode
License
Apache-2.0
Notes
This Pulumi package is based on the linode Terraform Provider.