UNPKG

@pulumi/consul

Version:

A Pulumi package for creating and managing consul resources.

106 lines (105 loc) 2.99 kB
import * as pulumi from "@pulumi/pulumi"; /** * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as consul from "@pulumi/consul"; * * const test = new consul.AclPolicy("test", { * name: "test", * rules: "node \"\" { policy = \"read\" }", * datacenters: ["dc1"], * }); * const testAclToken = new consul.AclToken("test", { * description: "test", * policies: [test.name], * local: true, * }); * const read = consul.getAclTokenSecretIdOutput({ * accessorId: testAclToken.id, * pgpKey: "keybase:my_username", * }); * export const consulAclTokenSecretId = read.apply(read => read.encryptedSecretId); * ``` */ export declare function getAclTokenSecretId(args: GetAclTokenSecretIdArgs, opts?: pulumi.InvokeOptions): Promise<GetAclTokenSecretIdResult>; /** * A collection of arguments for invoking getAclTokenSecretId. */ export interface GetAclTokenSecretIdArgs { /** * The accessor ID of the ACL token. */ accessorId: string; /** * The namespace to lookup the token. */ namespace?: string; /** * The partition to lookup the token. */ partition?: string; pgpKey?: string; } /** * A collection of values returned by getAclTokenSecretId. */ export interface GetAclTokenSecretIdResult { readonly accessorId: string; readonly encryptedSecretId: string; /** * The provider-assigned unique ID for this managed resource. */ readonly id: string; readonly namespace?: string; readonly partition?: string; readonly pgpKey?: string; /** * The secret ID of the ACL token if `pgpKey` has not been set. */ readonly secretId: string; } /** * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as consul from "@pulumi/consul"; * * const test = new consul.AclPolicy("test", { * name: "test", * rules: "node \"\" { policy = \"read\" }", * datacenters: ["dc1"], * }); * const testAclToken = new consul.AclToken("test", { * description: "test", * policies: [test.name], * local: true, * }); * const read = consul.getAclTokenSecretIdOutput({ * accessorId: testAclToken.id, * pgpKey: "keybase:my_username", * }); * export const consulAclTokenSecretId = read.apply(read => read.encryptedSecretId); * ``` */ export declare function getAclTokenSecretIdOutput(args: GetAclTokenSecretIdOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetAclTokenSecretIdResult>; /** * A collection of arguments for invoking getAclTokenSecretId. */ export interface GetAclTokenSecretIdOutputArgs { /** * The accessor ID of the ACL token. */ accessorId: pulumi.Input<string>; /** * The namespace to lookup the token. */ namespace?: pulumi.Input<string>; /** * The partition to lookup the token. */ partition?: pulumi.Input<string>; pgpKey?: pulumi.Input<string>; }