All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.equinix.pulumi.networkedge.SshKey Maven / Gradle / Ivy

There is a newer version: 0.21.0
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.equinix.pulumi.networkedge;

import com.equinix.pulumi.Utilities;
import com.equinix.pulumi.networkedge.SshKeyArgs;
import com.equinix.pulumi.networkedge.inputs.SshKeyState;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.String;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * Resource `equinix.networkedge.SshKey` allows creation and management of Equinix Network Edge SSH keys.
 * 
 * ## Example Usage
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.equinix.networkedge.SshKey;
 * import com.pulumi.equinix.networkedge.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 }{{@code
 *     public static void main(String[] args) }{{@code
 *         Pulumi.run(App::stack);
 *     }}{@code
 * 
 *     public static void stack(Context ctx) }{{@code
 *         var john = new SshKey("john", SshKeyArgs.builder()
 *             .name("johnKent")
 *             .publicKey("""
 *   ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDpXGdxljAyPp9vH97436U171cX
 *   2gRkfPnpL8ebrk7ZBeeIpdjtd8mYpXf6fOI0o91TQXZTYtjABzeRgg6/m9hsMOnTHjzWpFyuj/hiPu
 *   iie1WtT4NffSH1ALQFX/azouBLmdNiYFMLfEVPZleergAqsYOHGCiQuR6Qh5j0yc5Wx+LKxiRZyjsS
 *   qo+EB8V6xBXi2i5PDJXK+dYG8YU9vdNeQdB84HvTWcGEnLR5w7pgC74pBVwzs3oWLy+3jWS0TKKtfl
 *   mryeFRufXq87gEkC1MOWX88uQgjyCsemuhPdN++2WS57gu7vcqCMwMDZa7dukRS3JANBtbs7qQhp9N
 *   w2PB4q6tohqUnSDxNjCqcoGeMNg/0kHeZcoVuznsjOrIDt0HgUApflkbtw1DP7Epfc2MJ0anf5GizM
 *   8UjMYiXEvv2U/qu8Vb7d5bxAshXM5nh67NSrgst9YzSSodjUCnFQkniz6KLrTkX6c2y2gJ5c9tWhg5
 *   SPkAc8OqLrmIwf5jGoHGh6eUJy7AtMcwE3iUpbrLw8EEoZDoDXkzh+RbOtSNKXWV4EAXsIhjQusCOW
 *   WQnuAHCy9N4Td0Sntzu/xhCZ8xN0oO67Cqlsk98xSRLXeg21PuuhOYJw0DLF6L68zU2OO0RzqoNq/F
 *   jIsltSUJPAIfYKL0yEefeNWOXSrasI1ezw== John.Kent}{@literal @}{@code company.com
 *             """)
 *             .type("RSA")
 *             .projectId("a86d7112-d740-4758-9c9c-31e66373746b")
 *             .build());
 * 
 *     }}{@code
 * }}{@code
 * }
 * 
* * ## Import * * This resource can be imported using an existing ID: * * ```sh * $ pulumi import equinix:networkedge/sshKey:SshKey example {existing_id} * ``` * */ @ResourceType(type="equinix:networkedge/sshKey:SshKey") public class SshKey extends com.pulumi.resources.CustomResource { /** * The name of SSH key used for identification. * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return The name of SSH key used for identification. * */ public Output name() { return this.name; } /** * Unique Identifier for the project resource where the SSH key is scoped to.If you leave it out, the ssh key will be created under the default project id of your organization. * */ @Export(name="projectId", refs={String.class}, tree="[0]") private Output projectId; /** * @return Unique Identifier for the project resource where the SSH key is scoped to.If you leave it out, the ssh key will be created under the default project id of your organization. * */ public Output projectId() { return this.projectId; } /** * The SSH public key. If this is a file, it can be read using the file interpolation function. * */ @Export(name="publicKey", refs={String.class}, tree="[0]") private Output publicKey; /** * @return The SSH public key. If this is a file, it can be read using the file interpolation function. * */ public Output publicKey() { return this.publicKey; } /** * The type of SSH key: `RSA` (default) or `DSA`. * */ @Export(name="type", refs={String.class}, tree="[0]") private Output type; /** * @return The type of SSH key: `RSA` (default) or `DSA`. * */ public Output> type() { return Codegen.optional(this.type); } /** * The unique identifier of the key * */ @Export(name="uuid", refs={String.class}, tree="[0]") private Output uuid; /** * @return The unique identifier of the key * */ public Output uuid() { return this.uuid; } /** * * @param name The _unique_ name of the resulting resource. */ public SshKey(java.lang.String name) { this(name, SshKeyArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public SshKey(java.lang.String name, SshKeyArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public SshKey(java.lang.String name, SshKeyArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("equinix:networkedge/sshKey:SshKey", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private SshKey(java.lang.String name, Output id, @Nullable SshKeyState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("equinix:networkedge/sshKey:SshKey", name, state, makeResourceOptions(options, id), false); } private static SshKeyArgs makeArgs(SshKeyArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? SshKeyArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state * @param options Optional settings to control the behavior of the CustomResource. */ public static SshKey get(java.lang.String name, Output id, @Nullable SshKeyState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new SshKey(name, id, state, options); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy