@pulumi/consul
Version:
A Pulumi package for creating and managing consul resources.
111 lines (110 loc) • 3.63 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "./types/input";
import * as outputs from "./types/output";
/**
* The `consul.getNodes` data source returns a list of Consul nodes that have
* been registered with the Consul cluster in a given datacenter. By specifying a
* different datacenter in the `queryOptions` it is possible to retrieve a list of
* nodes from a different WAN-attached Consul datacenter.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as consul from "@pulumi/consul";
* import * as example from "@pulumi/example";
* import * as std from "@pulumi/std";
*
* const read_dc1_nodes = consul.getNodes({
* queryOptions: [{
* datacenter: "dc1",
* }],
* });
* // Set the description to a whitespace delimited list of the node names
* const app = new example.index.Resource("app", {description: std.join({
* separator: " ",
* input: std.formatlist({
* input: "%s",
* args: [nodeNames],
* }).result,
* }).result});
* ```
*/
/** @deprecated getCatalogNodes has been deprecated in favor of getNodes */
export declare function getCatalogNodes(args?: GetCatalogNodesArgs, opts?: pulumi.InvokeOptions): Promise<GetCatalogNodesResult>;
/**
* A collection of arguments for invoking getCatalogNodes.
*/
export interface GetCatalogNodesArgs {
/**
* See below.
*/
queryOptions?: inputs.GetCatalogNodesQueryOption[];
}
/**
* A collection of values returned by getCatalogNodes.
*/
export interface GetCatalogNodesResult {
/**
* The datacenter the keys are being read from to.
*/
readonly datacenter: string;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
/**
* A list of the Consul node IDs.
*/
readonly nodeIds: string[];
/**
* A list of the Consul node names.
*/
readonly nodeNames: string[];
/**
* A list of nodes and details about each Consul agent. The list of
* per-node attributes is detailed below.
*/
readonly nodes: outputs.GetCatalogNodesNode[];
readonly queryOptions?: outputs.GetCatalogNodesQueryOption[];
}
/**
* The `consul.getNodes` data source returns a list of Consul nodes that have
* been registered with the Consul cluster in a given datacenter. By specifying a
* different datacenter in the `queryOptions` it is possible to retrieve a list of
* nodes from a different WAN-attached Consul datacenter.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as consul from "@pulumi/consul";
* import * as example from "@pulumi/example";
* import * as std from "@pulumi/std";
*
* const read_dc1_nodes = consul.getNodes({
* queryOptions: [{
* datacenter: "dc1",
* }],
* });
* // Set the description to a whitespace delimited list of the node names
* const app = new example.index.Resource("app", {description: std.join({
* separator: " ",
* input: std.formatlist({
* input: "%s",
* args: [nodeNames],
* }).result,
* }).result});
* ```
*/
/** @deprecated getCatalogNodes has been deprecated in favor of getNodes */
export declare function getCatalogNodesOutput(args?: GetCatalogNodesOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetCatalogNodesResult>;
/**
* A collection of arguments for invoking getCatalogNodes.
*/
export interface GetCatalogNodesOutputArgs {
/**
* See below.
*/
queryOptions?: pulumi.Input<pulumi.Input<inputs.GetCatalogNodesQueryOptionArgs>[]>;
}