UNPKG

@pulumi/consul

Version:

A Pulumi package for creating and managing consul resources.

117 lines (116 loc) 3.93 kB
import * as pulumi from "@pulumi/pulumi"; /** * !> The `consul.AgentService` resource has been deprecated in version 2.0.0 of the provider * and will be removed in a future release. Please read the [upgrade guide](https://www.terraform.io/docs/providers/consul/guides/upgrading.html#deprecation-of-consul_agent_service) * for more information. * * Provides access to the agent service data in Consul. This can be used to * define a service associated with a particular agent. Currently, defining * health checks for an agent service is not supported. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as consul from "@pulumi/consul"; * * const app = new consul.AgentService("app", { * address: "www.google.com", * name: "google", * port: 80, * tags: [ * "tag0", * "tag1", * ], * }); * ``` */ export declare class AgentService extends pulumi.CustomResource { /** * Get an existing AgentService 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 Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AgentServiceState, opts?: pulumi.CustomResourceOptions): AgentService; /** * Returns true if the given object is an instance of AgentService. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is AgentService; /** * The address of the service. Defaults to the * address of the agent. */ readonly address: pulumi.Output<string>; /** * The name of the service. */ readonly name: pulumi.Output<string>; /** * The port of the service. */ readonly port: pulumi.Output<number | undefined>; /** * A list of values that are opaque to Consul, * but can be used to distinguish between services or nodes. */ readonly tags: pulumi.Output<string[] | undefined>; /** * Create a AgentService resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args?: AgentServiceArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering AgentService resources. */ export interface AgentServiceState { /** * The address of the service. Defaults to the * address of the agent. */ address?: pulumi.Input<string>; /** * The name of the service. */ name?: pulumi.Input<string>; /** * The port of the service. */ port?: pulumi.Input<number>; /** * A list of values that are opaque to Consul, * but can be used to distinguish between services or nodes. */ tags?: pulumi.Input<pulumi.Input<string>[]>; } /** * The set of arguments for constructing a AgentService resource. */ export interface AgentServiceArgs { /** * The address of the service. Defaults to the * address of the agent. */ address?: pulumi.Input<string>; /** * The name of the service. */ name?: pulumi.Input<string>; /** * The port of the service. */ port?: pulumi.Input<number>; /** * A list of values that are opaque to Consul, * but can be used to distinguish between services or nodes. */ tags?: pulumi.Input<pulumi.Input<string>[]>; }