@pulumi/hcloud
Version:
A Pulumi package for creating and managing hcloud cloud resources.
73 lines (72 loc) • 2.08 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as outputs from "./types/output";
/**
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as hcloud from "@pulumi/hcloud";
*
* const all = hcloud.getSshKeys({});
* const byLabel = hcloud.getSshKeys({
* withSelector: "foo=bar",
* });
* const main = new hcloud.Server("main", {sshKeys: all.then(all => all.sshKeys.map(__item => __item.name))});
* ```
*/
export declare function getSshKeys(args?: GetSshKeysArgs, opts?: pulumi.InvokeOptions): Promise<GetSshKeysResult>;
/**
* A collection of arguments for invoking getSshKeys.
*/
export interface GetSshKeysArgs {
/**
* The ID of this resource.
*/
id?: string;
/**
* Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
*/
withSelector?: string;
}
/**
* A collection of values returned by getSshKeys.
*/
export interface GetSshKeysResult {
/**
* The ID of this resource.
*/
readonly id?: string;
readonly sshKeys: outputs.GetSshKeysSshKey[];
/**
* Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
*/
readonly withSelector?: string;
}
/**
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as hcloud from "@pulumi/hcloud";
*
* const all = hcloud.getSshKeys({});
* const byLabel = hcloud.getSshKeys({
* withSelector: "foo=bar",
* });
* const main = new hcloud.Server("main", {sshKeys: all.then(all => all.sshKeys.map(__item => __item.name))});
* ```
*/
export declare function getSshKeysOutput(args?: GetSshKeysOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetSshKeysResult>;
/**
* A collection of arguments for invoking getSshKeys.
*/
export interface GetSshKeysOutputArgs {
/**
* The ID of this resource.
*/
id?: pulumi.Input<string>;
/**
* Filter results using a [Label Selector](https://docs.hetzner.cloud/#label-selector)
*/
withSelector?: pulumi.Input<string>;
}