ovh.Me.SshKey

Creates an SSH Key.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Ovh = Lbrlabs.PulumiPackage.Ovh;

return await Deployment.RunAsync(() => 
{
    var mykey = new Ovh.Me.SshKey("mykey", new()
    {
        Key = "ssh-ed25519 AAAAC3...",
        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.NewSshKey(ctx, "mykey", &Me.SshKeyArgs{
			Key:     pulumi.String("ssh-ed25519 AAAAC3..."),
			KeyName: pulumi.String("mykey"),
		})
		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.SshKey;
import com.pulumi.ovh.Me.SshKeyArgs;
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) {
        var mykey = new SshKey("mykey", SshKeyArgs.builder()        
            .key("ssh-ed25519 AAAAC3...")
            .keyName("mykey")
            .build());

    }
}
import pulumi
import lbrlabs_pulumi_ovh as ovh

mykey = ovh.me.SshKey("mykey",
    key="ssh-ed25519 AAAAC3...",
    key_name="mykey")
import * as pulumi from "@pulumi/pulumi";
import * as ovh from "@lbrlabs/pulumi-ovh";

const mykey = new ovh.me.SshKey("mykey", {
    key: "ssh-ed25519 AAAAC3...",
    keyName: "mykey",
});
resources:
  mykey:
    type: ovh:Me:SshKey
    properties:
      key: ssh-ed25519 AAAAC3...
      keyName: mykey

Create SshKey Resource

new SshKey(name: string, args: SshKeyArgs, opts?: CustomResourceOptions);
@overload
def SshKey(resource_name: str,
           opts: Optional[ResourceOptions] = None,
           default: Optional[bool] = None,
           key: Optional[str] = None,
           key_name: Optional[str] = None)
@overload
def SshKey(resource_name: str,
           args: SshKeyArgs,
           opts: Optional[ResourceOptions] = None)
func NewSshKey(ctx *Context, name string, args SshKeyArgs, opts ...ResourceOption) (*SshKey, error)
public SshKey(string name, SshKeyArgs args, CustomResourceOptions? opts = null)
public SshKey(String name, SshKeyArgs args)
public SshKey(String name, SshKeyArgs args, CustomResourceOptions options)
type: ovh:Me:SshKey
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args SshKeyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args SshKeyArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args SshKeyArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args SshKeyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args SshKeyArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

SshKey Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The SshKey resource accepts the following input properties:

Key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

KeyName string

The friendly name of this SSH key.

Default bool

True when this public SSH key is used for rescue mode and reinstallations.

Key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

KeyName string

The friendly name of this SSH key.

Default bool

True when this public SSH key is used for rescue mode and reinstallations.

key String

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName String

The friendly name of this SSH key.

default_ Boolean

True when this public SSH key is used for rescue mode and reinstallations.

key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName string

The friendly name of this SSH key.

default boolean

True when this public SSH key is used for rescue mode and reinstallations.

key str

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

key_name str

The friendly name of this SSH key.

default bool

True when this public SSH key is used for rescue mode and reinstallations.

key String

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName String

The friendly name of this SSH key.

default Boolean

True when this public SSH key is used for rescue mode and reinstallations.

Outputs

All input properties are implicitly available as output properties. Additionally, the SshKey resource produces the following output properties:

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up Existing SshKey Resource

Get an existing SshKey resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: SshKeyState, opts?: CustomResourceOptions): SshKey
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        default: Optional[bool] = None,
        key: Optional[str] = None,
        key_name: Optional[str] = None) -> SshKey
func GetSshKey(ctx *Context, name string, id IDInput, state *SshKeyState, opts ...ResourceOption) (*SshKey, error)
public static SshKey Get(string name, Input<string> id, SshKeyState? state, CustomResourceOptions? opts = null)
public static SshKey get(String name, Output<String> id, SshKeyState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Default bool

True when this public SSH key is used for rescue mode and reinstallations.

Key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

KeyName string

The friendly name of this SSH key.

Default bool

True when this public SSH key is used for rescue mode and reinstallations.

Key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

KeyName string

The friendly name of this SSH key.

default_ Boolean

True when this public SSH key is used for rescue mode and reinstallations.

key String

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName String

The friendly name of this SSH key.

default boolean

True when this public SSH key is used for rescue mode and reinstallations.

key string

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName string

The friendly name of this SSH key.

default bool

True when this public SSH key is used for rescue mode and reinstallations.

key str

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

key_name str

The friendly name of this SSH key.

default Boolean

True when this public SSH key is used for rescue mode and reinstallations.

key String

The content of the public key in the form "ssh-algo content", e.g. "ssh-ed25519 AAAAC3...".

keyName String

The friendly name of this SSH key.

Package Details

Repository
ovh lbrlabs/pulumi-ovh
License
Apache-2.0
Notes

This Pulumi package is based on the ovh Terraform Provider.