Pulumi Consul

This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-consul repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-consul repo.

class pulumi_consul.AclAuthMethod(resource_name, opts=None, config=None, description=None, name=None, type=None, __props__=None, __name__=None, __opts__=None)

Starting with Consul 1.5.0, the .AclAuthMethod resource can be used to managed Consul ACL auth methods.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • config (pulumi.Input[dict]) – The raw configuration for this ACL auth method.

  • description (pulumi.Input[str]) – A free form human readable description of the auth method.

  • name (pulumi.Input[str]) – The name of the ACL auth method.

  • type (pulumi.Input[str]) – The type of the ACL auth method.

config = None

The raw configuration for this ACL auth method.

description = None

A free form human readable description of the auth method.

name = None

The name of the ACL auth method.

type = None

The type of the ACL auth method.

static get(resource_name, id, opts=None, config=None, description=None, name=None, type=None)

Get an existing AclAuthMethod resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • config (pulumi.Input[dict]) – The raw configuration for this ACL auth method.

  • description (pulumi.Input[str]) – A free form human readable description of the auth method.

  • name (pulumi.Input[str]) – The name of the ACL auth method.

  • type (pulumi.Input[str]) – The type of the ACL auth method.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AclBindingRule(resource_name, opts=None, auth_method=None, bind_name=None, bind_type=None, description=None, selector=None, __props__=None, __name__=None, __opts__=None)

Starting with Consul 1.5.0, the .AclBindingRule resource can be used to managed Consul ACL binding rules.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • auth_method (pulumi.Input[str]) – The name of the ACL auth method this rule apply.

  • bind_name (pulumi.Input[str]) – The name to bind to a token at login-time.

  • bind_type (pulumi.Input[str]) – Specifies the way the binding rule affects a token created at login.

  • description (pulumi.Input[str]) – A free form human readable description of the binding rule.

  • selector (pulumi.Input[str]) – The expression used to math this rule against valid identities returned from an auth method validation.

auth_method = None

The name of the ACL auth method this rule apply.

bind_name = None

The name to bind to a token at login-time.

bind_type = None

Specifies the way the binding rule affects a token created at login.

description = None

A free form human readable description of the binding rule.

selector = None

The expression used to math this rule against valid identities returned from an auth method validation.

static get(resource_name, id, opts=None, auth_method=None, bind_name=None, bind_type=None, description=None, selector=None)

Get an existing AclBindingRule resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • auth_method (pulumi.Input[str]) – The name of the ACL auth method this rule apply.

  • bind_name (pulumi.Input[str]) – The name to bind to a token at login-time.

  • bind_type (pulumi.Input[str]) – Specifies the way the binding rule affects a token created at login.

  • description (pulumi.Input[str]) – A free form human readable description of the binding rule.

  • selector (pulumi.Input[str]) – The expression used to math this rule against valid identities returned from an auth method validation.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AclPolicy(resource_name, opts=None, datacenters=None, description=None, name=None, rules=None, __props__=None, __name__=None, __opts__=None)

Starting with Consul 1.4.0, the .AclPolicy can be used to managed Consul ACL policies.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenters (pulumi.Input[list]) – The datacenters of the policy.

  • description (pulumi.Input[str]) – The description of the policy.

  • name (pulumi.Input[str]) – The name of the policy.

  • rules (pulumi.Input[str]) – The rules of the policy.

datacenters = None

The datacenters of the policy.

description = None

The description of the policy.

name = None

The name of the policy.

rules = None

The rules of the policy.

static get(resource_name, id, opts=None, datacenters=None, description=None, name=None, rules=None)

Get an existing AclPolicy resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenters (pulumi.Input[list]) – The datacenters of the policy.

  • description (pulumi.Input[str]) – The description of the policy.

  • name (pulumi.Input[str]) – The name of the policy.

  • rules (pulumi.Input[str]) – The rules of the policy.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AclRole(resource_name, opts=None, description=None, name=None, policies=None, service_identities=None, __props__=None, __name__=None, __opts__=None)

Starting with Consul 1.5.0, the .AclRole can be used to managed Consul ACL roles.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • description (pulumi.Input[str]) – A free form human readable description of the role.

  • name (pulumi.Input[str]) – The name of the ACL role.

  • policies (pulumi.Input[list]) – The list of policies that should be applied to the role.

  • service_identities (pulumi.Input[list]) – The list of service identities that should be applied to the role.

The service_identities object supports the following:

  • datacenters (pulumi.Input[list]) - The datacenters the effective policy is valid within.

  • serviceName (pulumi.Input[str]) - The name of the service.

description = None

A free form human readable description of the role.

name = None

The name of the ACL role.

policies = None

The list of policies that should be applied to the role.

service_identities = None

The list of service identities that should be applied to the role.

  • datacenters (list) - The datacenters the effective policy is valid within.

  • serviceName (str) - The name of the service.

static get(resource_name, id, opts=None, description=None, name=None, policies=None, service_identities=None)

Get an existing AclRole resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • description (pulumi.Input[str]) – A free form human readable description of the role.

  • name (pulumi.Input[str]) – The name of the ACL role.

  • policies (pulumi.Input[list]) – The list of policies that should be applied to the role.

  • service_identities (pulumi.Input[list]) – The list of service identities that should be applied to the role.

The service_identities object supports the following:

  • datacenters (pulumi.Input[list]) - The datacenters the effective policy is valid within.

  • serviceName (pulumi.Input[str]) - The name of the service.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AclToken(resource_name, opts=None, accessor_id=None, description=None, local=None, policies=None, __props__=None, __name__=None, __opts__=None)

The .AclToken resource writes an ACL token into Consul.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • accessor_id (pulumi.Input[str]) – The uuid of the token. If omitted, Consul will generate a random uuid.

  • description (pulumi.Input[str]) – The description of the token.

  • local (pulumi.Input[bool]) – The flag to set the token local to the current datacenter.

  • policies (pulumi.Input[list]) – The list of policies attached to the token.

accessor_id = None

The uuid of the token. If omitted, Consul will generate a random uuid.

description = None

The description of the token.

local = None

The flag to set the token local to the current datacenter.

policies = None

The list of policies attached to the token.

static get(resource_name, id, opts=None, accessor_id=None, description=None, local=None, policies=None)

Get an existing AclToken resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • accessor_id (pulumi.Input[str]) – The uuid of the token. If omitted, Consul will generate a random uuid.

  • description (pulumi.Input[str]) – The description of the token.

  • local (pulumi.Input[bool]) – The flag to set the token local to the current datacenter.

  • policies (pulumi.Input[list]) – The list of policies attached to the token.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AclTokenPolicyAttachment(resource_name, opts=None, policy=None, token_id=None, __props__=None, __name__=None, __opts__=None)

Create a AclTokenPolicyAttachment resource with the given unique name, props, and options.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • policy (pulumi.Input[str]) – The name of the policy attached to the token.

  • token_id (pulumi.Input[str]) – The id of the token.

policy = None

The name of the policy attached to the token.

token_id = None

The id of the token.

static get(resource_name, id, opts=None, policy=None, token_id=None)

Get an existing AclTokenPolicyAttachment resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • policy (pulumi.Input[str]) – The name of the policy attached to the token.

  • token_id (pulumi.Input[str]) – The id of the token.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AgentService(resource_name, opts=None, address=None, name=None, port=None, tags=None, __props__=None, __name__=None, __opts__=None)

!> The .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 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.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the service. Defaults to the address of the agent.

  • name (pulumi.Input[str]) – The name of the service.

  • port (pulumi.Input[float]) – The port of the service.

  • tags (pulumi.Input[list]) – A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

address = None

The address of the service. Defaults to the address of the agent.

name = None

The name of the service.

port = None

The port of the service.

tags = None

A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

static get(resource_name, id, opts=None, address=None, name=None, port=None, tags=None)

Get an existing AgentService resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the service. Defaults to the address of the agent.

  • name (pulumi.Input[str]) – The name of the service.

  • port (pulumi.Input[float]) – The port of the service.

  • tags (pulumi.Input[list]) – A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AutopilotConfig(resource_name, opts=None, cleanup_dead_servers=None, datacenter=None, disable_upgrade_migration=None, last_contact_threshold=None, max_trailing_logs=None, redundancy_zone_tag=None, server_stabilization_time=None, upgrade_version_tag=None, __props__=None, __name__=None, __opts__=None)

Provides access to the Autopilot Configuration of Consul to automatically manage Consul servers.

It includes to automatically cleanup dead servers, monitor the status of the Raft cluster and stable server introduction.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • cleanup_dead_servers (pulumi.Input[bool]) – Whether to remove failing servers when a replacement comes online. Defaults to true.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • disable_upgrade_migration (pulumi.Input[bool]) – Whether to disable upgrade migrations. Defaults to false.

  • last_contact_threshold (pulumi.Input[str]) – The time after which a server is considered as unhealthy and will be removed. Defaults to "200ms".

  • max_trailing_logs (pulumi.Input[float]) – The maximum number of Raft log entries a server can trail the leader. Defaults to 250.

  • redundancy_zone_tag (pulumi.Input[str]) – The redundancy zone tag to use. Consul will try to keep one voting server by zone to take advantage of isolated failure domains. Defaults to an empty string.

  • server_stabilization_time (pulumi.Input[str]) – The period to wait for a server to be healthy and stable before being promoted to a full, voting member. Defaults to "10s".

  • upgrade_version_tag (pulumi.Input[str]) – The tag to override the version information used during a migration. Defaults to an empty string.

cleanup_dead_servers = None

Whether to remove failing servers when a replacement comes online. Defaults to true.

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

disable_upgrade_migration = None

Whether to disable upgrade migrations. Defaults to false.

last_contact_threshold = None

The time after which a server is considered as unhealthy and will be removed. Defaults to "200ms".

max_trailing_logs = None

The maximum number of Raft log entries a server can trail the leader. Defaults to 250.

redundancy_zone_tag = None

The redundancy zone tag to use. Consul will try to keep one voting server by zone to take advantage of isolated failure domains. Defaults to an empty string.

server_stabilization_time = None

The period to wait for a server to be healthy and stable before being promoted to a full, voting member. Defaults to "10s".

upgrade_version_tag = None

The tag to override the version information used during a migration. Defaults to an empty string.

static get(resource_name, id, opts=None, cleanup_dead_servers=None, datacenter=None, disable_upgrade_migration=None, last_contact_threshold=None, max_trailing_logs=None, redundancy_zone_tag=None, server_stabilization_time=None, upgrade_version_tag=None)

Get an existing AutopilotConfig resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • cleanup_dead_servers (pulumi.Input[bool]) – Whether to remove failing servers when a replacement comes online. Defaults to true.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • disable_upgrade_migration (pulumi.Input[bool]) –

    Whether to disable upgrade migrations. Defaults to false.

  • last_contact_threshold (pulumi.Input[str]) – The time after which a server is considered as unhealthy and will be removed. Defaults to "200ms".

  • max_trailing_logs (pulumi.Input[float]) – The maximum number of Raft log entries a server can trail the leader. Defaults to 250.

  • redundancy_zone_tag (pulumi.Input[str]) –

    The redundancy zone tag to use. Consul will try to keep one voting server by zone to take advantage of isolated failure domains. Defaults to an empty string.

  • server_stabilization_time (pulumi.Input[str]) – The period to wait for a server to be healthy and stable before being promoted to a full, voting member. Defaults to "10s".

  • upgrade_version_tag (pulumi.Input[str]) – The tag to override the version information used during a migration. Defaults to an empty string.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.AwaitableGetAclAuthMethodResult(config=None, description=None, name=None, type=None, id=None)
class pulumi_consul.AwaitableGetAclPolicyResult(datacenters=None, description=None, name=None, rules=None, id=None)
class pulumi_consul.AwaitableGetAclRoleResult(description=None, name=None, policies=None, service_identities=None, id=None)
class pulumi_consul.AwaitableGetAclTokenResult(accessor_id=None, description=None, local=None, policies=None, id=None)
class pulumi_consul.AwaitableGetAclTokenSecretIdResult(accessor_id=None, encrypted_secret_id=None, pgp_key=None, secret_id=None, id=None)
class pulumi_consul.AwaitableGetAgentConfigResult(datacenter=None, node_id=None, node_name=None, revision=None, server=None, version=None, id=None)
class pulumi_consul.AwaitableGetAgentSelfResult(acl_datacenter=None, acl_default_policy=None, acl_disabled_ttl=None, acl_down_policy=None, acl_enforce08_semantics=None, acl_ttl=None, addresses=None, advertise_addr=None, advertise_addr_wan=None, advertise_addrs=None, atlas_join=None, bind_addr=None, bootstrap_expect=None, bootstrap_mode=None, check_deregister_interval_min=None, check_reap_interval=None, check_update_interval=None, client_addr=None, data_dir=None, datacenter=None, dev_mode=None, dns=None, dns_recursors=None, domain=None, enable_anonymous_signature=None, enable_coordinates=None, enable_debug=None, enable_remote_exec=None, enable_syslog=None, enable_ui=None, enable_update_check=None, id=None, leave_on_int=None, leave_on_term=None, log_level=None, name=None, performance=None, pid_file=None, ports=None, protocol_version=None, reconnect_timeout_lan=None, reconnect_timeout_wan=None, rejoin_after_leave=None, retry_joins=None, retry_join_ec2=None, retry_join_gce=None, retry_join_wans=None, retry_max_attempts=None, retry_max_attempts_wan=None, serf_lan_bind_addr=None, serf_wan_bind_addr=None, server_mode=None, server_name=None, session_ttl_min=None, start_joins=None, start_join_wans=None, syslog_facility=None, tagged_addresses=None, telemetry=None, tls_ca_file=None, tls_cert_file=None, tls_key_file=None, tls_min_version=None, tls_verify_incoming=None, tls_verify_outgoing=None, tls_verify_server_hostname=None, translate_wan_addrs=None, ui_dir=None, unix_sockets=None, version=None, version_prerelease=None, version_revision=None)
class pulumi_consul.AwaitableGetAutopilotHealthResult(datacenter=None, failure_tolerance=None, healthy=None, servers=None, id=None)
class pulumi_consul.AwaitableGetCatalogNodesResult(datacenter=None, node_ids=None, node_names=None, nodes=None, query_options=None, id=None)
class pulumi_consul.AwaitableGetCatalogServiceResult(datacenter=None, name=None, query_options=None, services=None, tag=None, id=None)
class pulumi_consul.AwaitableGetCatalogServicesResult(datacenter=None, names=None, query_options=None, services=None, id=None)
class pulumi_consul.AwaitableGetKeyPrefixResult(datacenter=None, path_prefix=None, subkey_collection=None, subkeys=None, token=None, var=None, id=None)
class pulumi_consul.AwaitableGetKeysResult(datacenter=None, keys=None, token=None, var=None, id=None)
class pulumi_consul.AwaitableGetNodesResult(datacenter=None, node_ids=None, node_names=None, nodes=None, query_options=None, id=None)
class pulumi_consul.AwaitableGetServiceHealthResult(datacenter=None, name=None, near=None, node_meta=None, passing=None, results=None, tag=None, wait_for=None, id=None)
class pulumi_consul.AwaitableGetServiceResult(datacenter=None, name=None, query_options=None, services=None, tag=None, id=None)
class pulumi_consul.AwaitableGetServicesResult(datacenter=None, names=None, query_options=None, services=None, id=None)
class pulumi_consul.CatalogEntry(resource_name, opts=None, address=None, datacenter=None, node=None, services=None, token=None, __props__=None, __name__=None, __opts__=None)

!> The .CatalogEntry 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 for more information.

Registers a node or service with the Consul Catalog. Currently, defining health checks is not supported.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the node being added to, or referenced in the catalog.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • node (pulumi.Input[str]) – The name of the node being added to, or referenced in the catalog.

  • services (pulumi.Input[list]) – A service to optionally associated with the node. Supported values are documented below.

  • token (pulumi.Input[str]) – ACL token.

The services object supports the following:

  • address (pulumi.Input[str]) - The address of the node being added to, or referenced in the catalog.

  • id (pulumi.Input[str])

  • name (pulumi.Input[str])

  • port (pulumi.Input[float])

  • tags (pulumi.Input[list])

address = None

The address of the node being added to, or referenced in the catalog.

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

node = None

The name of the node being added to, or referenced in the catalog.

services = None

A service to optionally associated with the node. Supported values are documented below.

  • address (str) - The address of the node being added to, or referenced in the catalog.

  • id (str)

  • name (str)

  • port (float)

  • tags (list)

token = None

ACL token.

static get(resource_name, id, opts=None, address=None, datacenter=None, node=None, services=None, token=None)

Get an existing CatalogEntry resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the node being added to, or referenced in the catalog.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • node (pulumi.Input[str]) – The name of the node being added to, or referenced in the catalog.

  • services (pulumi.Input[list]) – A service to optionally associated with the node. Supported values are documented below.

  • token (pulumi.Input[str]) – ACL token.

The services object supports the following:

  • address (pulumi.Input[str]) - The address of the node being added to, or referenced in the catalog.

  • id (pulumi.Input[str])

  • name (pulumi.Input[str])

  • port (pulumi.Input[float])

  • tags (pulumi.Input[list])

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.ConfigEntry(resource_name, opts=None, config_json=None, kind=None, name=None, __props__=None, __name__=None, __opts__=None)

The Configuration Entry resource can be used to provide cluster-wide defaults for various aspects of Consul.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • config_json (pulumi.Input[str]) – An arbitrary map of configuration values.

  • kind (pulumi.Input[str]) – The kind of configuration entry to register.

  • name (pulumi.Input[str]) – The name of the configuration entry being registred.

config_json = None

An arbitrary map of configuration values.

kind = None

The kind of configuration entry to register.

name = None

The name of the configuration entry being registred.

static get(resource_name, id, opts=None, config_json=None, kind=None, name=None)

Get an existing ConfigEntry resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • config_json (pulumi.Input[str]) – An arbitrary map of configuration values.

  • kind (pulumi.Input[str]) – The kind of configuration entry to register.

  • name (pulumi.Input[str]) – The name of the configuration entry being registred.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.GetAclAuthMethodResult(config=None, description=None, name=None, type=None, id=None)

A collection of values returned by getAclAuthMethod.

config = None

The configuration options of the ACL Auth Method.

description = None

The description of the ACL Auth Method.

type = None

The type of the ACL Auth Method.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAclPolicyResult(datacenters=None, description=None, name=None, rules=None, id=None)

A collection of values returned by getAclPolicy.

datacenters = None

The datacenters associated with the ACL Policy.

description = None

The description of the ACL Policy.

rules = None

The rules associated with the ACL Policy.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAclRoleResult(description=None, name=None, policies=None, service_identities=None, id=None)

A collection of values returned by getAclRole.

description = None

The description of the ACL Role.

policies = None

The list of policies associated with the ACL Role. Each entry has an id and a name attribute.

service_identities = None

The list of service identities associated with the ACL Role. Each entry has a service_name attribute and a list of datacenters.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAclTokenResult(accessor_id=None, description=None, local=None, policies=None, id=None)

A collection of values returned by getAclToken.

description = None

The description of the ACL token.

local = None

Whether the ACL token is local to the datacenter it was created within.

policies = None

A list of policies associated with the ACL token. Each entry has an id and a name attribute.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAclTokenSecretIdResult(accessor_id=None, encrypted_secret_id=None, pgp_key=None, secret_id=None, id=None)

A collection of values returned by getAclTokenSecretId.

secret_id = None

The secret ID of the ACL token if gpg_key has not been set.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAgentConfigResult(datacenter=None, node_id=None, node_name=None, revision=None, server=None, version=None, id=None)

A collection of values returned by getAgentConfig.

datacenter = None

The datacenter the agent is running in

node_id = None

The ID of the node the agent is running on

node_name = None

The name of the node the agent is running on

revision = None

The first 9 characters of the VCS revision of the build of Consul that is running

server = None

Boolean if the agent is a server or not

version = None

The version of the build of Consul that is running

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetAgentSelfResult(acl_datacenter=None, acl_default_policy=None, acl_disabled_ttl=None, acl_down_policy=None, acl_enforce08_semantics=None, acl_ttl=None, addresses=None, advertise_addr=None, advertise_addr_wan=None, advertise_addrs=None, atlas_join=None, bind_addr=None, bootstrap_expect=None, bootstrap_mode=None, check_deregister_interval_min=None, check_reap_interval=None, check_update_interval=None, client_addr=None, data_dir=None, datacenter=None, dev_mode=None, dns=None, dns_recursors=None, domain=None, enable_anonymous_signature=None, enable_coordinates=None, enable_debug=None, enable_remote_exec=None, enable_syslog=None, enable_ui=None, enable_update_check=None, id=None, leave_on_int=None, leave_on_term=None, log_level=None, name=None, performance=None, pid_file=None, ports=None, protocol_version=None, reconnect_timeout_lan=None, reconnect_timeout_wan=None, rejoin_after_leave=None, retry_joins=None, retry_join_ec2=None, retry_join_gce=None, retry_join_wans=None, retry_max_attempts=None, retry_max_attempts_wan=None, serf_lan_bind_addr=None, serf_wan_bind_addr=None, server_mode=None, server_name=None, session_ttl_min=None, start_joins=None, start_join_wans=None, syslog_facility=None, tagged_addresses=None, telemetry=None, tls_ca_file=None, tls_cert_file=None, tls_key_file=None, tls_min_version=None, tls_verify_incoming=None, tls_verify_outgoing=None, tls_verify_server_hostname=None, translate_wan_addrs=None, ui_dir=None, unix_sockets=None, version=None, version_prerelease=None, version_revision=None)

A collection of values returned by getAgentSelf.

dns = None

A map of DNS configuration attributes. See below for details on the contents of the dns attribute.

version = None

The version of the Consul agent.

  • version_prerelease

  • version_revision

class pulumi_consul.GetAutopilotHealthResult(datacenter=None, failure_tolerance=None, healthy=None, servers=None, id=None)

A collection of values returned by getAutopilotHealth.

failure_tolerance = None

The number of redundant healthy servers that could fail without causing an outage

healthy = None

Whether the server is healthy according to the current Autopilot configuration

servers = None

A list of server health information. See below for details on the available information.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetCatalogNodesResult(datacenter=None, node_ids=None, node_names=None, nodes=None, query_options=None, id=None)

A collection of values returned by getCatalogNodes.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetCatalogServiceResult(datacenter=None, name=None, query_options=None, services=None, tag=None, id=None)

A collection of values returned by getCatalogService.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetCatalogServicesResult(datacenter=None, names=None, query_options=None, services=None, id=None)

A collection of values returned by getCatalogServices.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetKeyPrefixResult(datacenter=None, path_prefix=None, subkey_collection=None, subkeys=None, token=None, var=None, id=None)

A collection of values returned by getKeyPrefix.

datacenter = None

The datacenter the keys are being read from.

path_prefix = None

the common prefix shared by all keys being read.

  • var.<name> - For each name given, the corresponding attribute has the value of the key.

subkeys = None

A map of the subkeys and values is set if no subkey block is provided.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetKeysResult(datacenter=None, keys=None, token=None, var=None, id=None)

A collection of values returned by getKeys.

datacenter = None

The datacenter the keys are being read from.

  • var.<name> - For each name given, the corresponding attribute has the value of the key.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetNodesResult(datacenter=None, node_ids=None, node_names=None, nodes=None, query_options=None, id=None)

A collection of values returned by getNodes.

datacenter = None

The datacenter the keys are being read from to.

node_ids = None

A list of the Consul node IDs.

node_names = None

A list of the Consul node names.

nodes = None

A list of nodes and details about each Consul agent. The list of per-node attributes is detailed below.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetServiceHealthResult(datacenter=None, name=None, near=None, node_meta=None, passing=None, results=None, tag=None, wait_for=None, id=None)

A collection of values returned by getServiceHealth.

datacenter = None

The datacenter in which the node is running.

name = None

The name of this health-check.

near = None

The node to which the result must be sorted to.

node_meta = None

The list of metadata to filter the nodes.

passing = None

Whether to return only nodes with all checks in the passing state.

results = None

A list of entries and details about each endpoint advertising a service. Each element in the list has three attributes: node, service and checks. The list of the attributes of each one is detailed below.

tag = None

The name of the tag used to filter the list.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetServiceResult(datacenter=None, name=None, query_options=None, services=None, tag=None, id=None)

A collection of values returned by getService.

datacenter = None

The datacenter the keys are being read from to.

name = None

The name of the service

services = None

A list of nodes and details about each endpoint advertising a service. Each element in the list is a map of attributes that correspond to each individual node. The list of per-node attributes is detailed below.

tag = None

The name of the tag used to filter the list of nodes in service.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.GetServicesResult(datacenter=None, names=None, query_options=None, services=None, id=None)

A collection of values returned by getServices.

datacenter = None

The datacenter the keys are being read from to.

id = None

id is the provider-assigned unique ID for this managed resource.

class pulumi_consul.Intention(resource_name, opts=None, action=None, description=None, destination_name=None, meta=None, source_name=None, __props__=None, __name__=None, __opts__=None)

Intentions are used to define rules for which services may connect to one another when using Consul Connect.

It is appropriate to either reference existing services or specify non-existent services that will be created in the future when creating intentions. This resource can be used in conjunction with the .Service datasource when referencing services registered on nodes that have a running Consul agent.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • action (pulumi.Input[str]) – The intention action. Must be one of allow or deny.

  • description (pulumi.Input[str]) – Optional description that can be used by Consul tooling, but is not used internally.

  • destination_name (pulumi.Input[str]) – The name of the destination service for the intention. This service does not have to exist.

  • meta (pulumi.Input[dict]) – Key/value pairs that are opaque to Consul and are associated with the intention.

  • source_name (pulumi.Input[str]) – The name of the source service for the intention. This service does not have to exist.

action = None

The intention action. Must be one of allow or deny.

description = None

Optional description that can be used by Consul tooling, but is not used internally.

destination_name = None

The name of the destination service for the intention. This service does not have to exist.

meta = None

Key/value pairs that are opaque to Consul and are associated with the intention.

source_name = None

The name of the source service for the intention. This service does not have to exist.

static get(resource_name, id, opts=None, action=None, description=None, destination_name=None, meta=None, source_name=None)

Get an existing Intention resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • action (pulumi.Input[str]) – The intention action. Must be one of allow or deny.

  • description (pulumi.Input[str]) – Optional description that can be used by Consul tooling, but is not used internally.

  • destination_name (pulumi.Input[str]) – The name of the destination service for the intention. This service does not have to exist.

  • meta (pulumi.Input[dict]) – Key/value pairs that are opaque to Consul and are associated with the intention.

  • source_name (pulumi.Input[str]) – The name of the source service for the intention. This service does not have to exist.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.KeyPrefix(resource_name, opts=None, datacenter=None, path_prefix=None, subkey_collection=None, subkeys=None, token=None, __props__=None, __name__=None, __opts__=None)

Create a KeyPrefix resource with the given unique name, props, and options.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • path_prefix (pulumi.Input[str]) – Specifies the common prefix shared by all keys that will be managed by this resource instance. In most cases this will end with a slash, to manage a “folder” of keys.

  • subkey_collection (pulumi.Input[list]) – A subkey to add. Supported values documented below. Multiple blocks supported.

  • subkeys (pulumi.Input[dict]) – A mapping from subkey name (which will be appended to the given path_prefix) to the value that should be stored at that key. Use slashes, as shown in the above example, to create “sub-folders” under the given path prefix.

  • token (pulumi.Input[str]) – The ACL token to use. This overrides the token that the agent provides by default.

The subkey_collection object supports the following:

  • flags (pulumi.Input[float])

  • path (pulumi.Input[str])

  • value (pulumi.Input[str])

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

path_prefix = None

Specifies the common prefix shared by all keys that will be managed by this resource instance. In most cases this will end with a slash, to manage a “folder” of keys.

subkey_collection = None

A subkey to add. Supported values documented below. Multiple blocks supported.

  • flags (float)

  • path (str)

  • value (str)

subkeys = None

A mapping from subkey name (which will be appended to the given path_prefix) to the value that should be stored at that key. Use slashes, as shown in the above example, to create “sub-folders” under the given path prefix.

token = None

The ACL token to use. This overrides the token that the agent provides by default.

static get(resource_name, id, opts=None, datacenter=None, path_prefix=None, subkey_collection=None, subkeys=None, token=None)

Get an existing KeyPrefix resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • path_prefix (pulumi.Input[str]) – Specifies the common prefix shared by all keys that will be managed by this resource instance. In most cases this will end with a slash, to manage a “folder” of keys.

  • subkey_collection (pulumi.Input[list]) – A subkey to add. Supported values documented below. Multiple blocks supported.

  • subkeys (pulumi.Input[dict]) – A mapping from subkey name (which will be appended to the given path_prefix) to the value that should be stored at that key. Use slashes, as shown in the above example, to create “sub-folders” under the given path prefix.

  • token (pulumi.Input[str]) – The ACL token to use. This overrides the token that the agent provides by default.

The subkey_collection object supports the following:

  • flags (pulumi.Input[float])

  • path (pulumi.Input[str])

  • value (pulumi.Input[str])

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.Keys(resource_name, opts=None, datacenter=None, keys=None, token=None, __props__=None, __name__=None, __opts__=None)

Create a Keys resource with the given unique name, props, and options.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • keys (pulumi.Input[list]) – Specifies a key in Consul to be written. Supported values documented below.

  • token (pulumi.Input[str]) – The ACL token to use. This overrides the token that the agent provides by default.

The keys object supports the following:

  • default (pulumi.Input[str])

  • delete (pulumi.Input[bool])

  • flags (pulumi.Input[float])

  • name (pulumi.Input[str])

  • path (pulumi.Input[str])

  • value (pulumi.Input[str])

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

keys = None

Specifies a key in Consul to be written. Supported values documented below.

  • default (str)

  • delete (bool)

  • flags (float)

  • name (str)

  • path (str)

  • value (str)

token = None

The ACL token to use. This overrides the token that the agent provides by default.

static get(resource_name, id, opts=None, datacenter=None, keys=None, token=None, var=None)

Get an existing Keys resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • keys (pulumi.Input[list]) – Specifies a key in Consul to be written. Supported values documented below.

  • token (pulumi.Input[str]) – The ACL token to use. This overrides the token that the agent provides by default.

The keys object supports the following:

  • default (pulumi.Input[str])

  • delete (pulumi.Input[bool])

  • flags (pulumi.Input[float])

  • name (pulumi.Input[str])

  • path (pulumi.Input[str])

  • value (pulumi.Input[str])

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.Node(resource_name, opts=None, address=None, datacenter=None, meta=None, name=None, token=None, __props__=None, __name__=None, __opts__=None)

Provides access to Node data in Consul. This can be used to define a node. Currently, defining health checks is not supported.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the node being added to, or referenced in the catalog.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • meta (pulumi.Input[dict]) – Key/value pairs that are associated with the node.

  • name (pulumi.Input[str]) – The name of the node being added to, or referenced in the catalog.

address = None

The address of the node being added to, or referenced in the catalog.

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

meta = None

Key/value pairs that are associated with the node.

name = None

The name of the node being added to, or referenced in the catalog.

static get(resource_name, id, opts=None, address=None, datacenter=None, meta=None, name=None, token=None)

Get an existing Node resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the node being added to, or referenced in the catalog.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • meta (pulumi.Input[dict]) – Key/value pairs that are associated with the node.

  • name (pulumi.Input[str]) – The name of the node being added to, or referenced in the catalog.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.PreparedQuery(resource_name, opts=None, connect=None, datacenter=None, dns=None, failover=None, name=None, near=None, only_passing=None, service=None, session=None, stored_token=None, tags=None, template=None, token=None, __props__=None, __name__=None, __opts__=None)

Create a PreparedQuery resource with the given unique name, props, and options.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • connect (pulumi.Input[bool]) – When true the prepared query will return connect proxy services for a queried service. Conditions such as tags in the prepared query will be matched against the proxy service. Defaults to false.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • dns (pulumi.Input[dict]) – Settings for controlling the DNS response details.

  • failover (pulumi.Input[dict]) – Options for controlling behavior when no healthy nodes are available in the local DC.

  • name (pulumi.Input[str]) – The name of the prepared query. Used to identify the prepared query during requests. Can be specified as an empty string to configure the query as a catch-all.

  • near (pulumi.Input[str]) – Allows specifying the name of a node to sort results near using Consul’s distance sorting and network coordinates. The magic _agent value can be used to always sort nearest the node servicing the request.

  • only_passing (pulumi.Input[bool]) – When true, the prepared query will only return nodes with passing health checks in the result.

  • service (pulumi.Input[str]) – The name of the service to query.

  • session (pulumi.Input[str]) – The name of the Consul session to tie this query’s lifetime to. This is an advanced parameter that should not be used without a complete understanding of Consul sessions and the implications of their use (it is recommended to leave this blank in nearly all cases). If this parameter is omitted the query will not expire.

  • stored_token (pulumi.Input[str]) – The ACL token to store with the prepared query. This token will be used by default whenever the query is executed.

  • tags (pulumi.Input[list]) – The list of required and/or disallowed tags. If a tag is in this list it must be present. If the tag is preceded with a “!” then it is disallowed.

  • template (pulumi.Input[dict]) – Query templating options. This is used to make a single prepared query respond to many different requests.

  • token (pulumi.Input[str]) – The ACL token to use when saving the prepared query. This overrides the token that the agent provides by default.

The dns object supports the following:

  • ttl (pulumi.Input[str]) - The TTL to send when returning DNS results.

The failover object supports the following:

  • datacenters (pulumi.Input[list]) - Remote datacenters to return results from.

  • nearestN (pulumi.Input[float]) - Return results from this many datacenters, sorted in ascending order of estimated RTT.

The template object supports the following:

  • regexp (pulumi.Input[str]) - The regular expression to match with. When using name_prefix_match, this regex is applied against the query name.

  • type (pulumi.Input[str]) - The type of template matching to perform. Currently only name_prefix_match is supported.

connect = None

When true the prepared query will return connect proxy services for a queried service. Conditions such as tags in the prepared query will be matched against the proxy service. Defaults to false.

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

dns = None

Settings for controlling the DNS response details.

  • ttl (str) - The TTL to send when returning DNS results.

failover = None

Options for controlling behavior when no healthy nodes are available in the local DC.

  • datacenters (list) - Remote datacenters to return results from.

  • nearestN (float) - Return results from this many datacenters, sorted in ascending order of estimated RTT.

name = None

The name of the prepared query. Used to identify the prepared query during requests. Can be specified as an empty string to configure the query as a catch-all.

near = None

Allows specifying the name of a node to sort results near using Consul’s distance sorting and network coordinates. The magic _agent value can be used to always sort nearest the node servicing the request.

only_passing = None

When true, the prepared query will only return nodes with passing health checks in the result.

service = None

The name of the service to query.

session = None

The name of the Consul session to tie this query’s lifetime to. This is an advanced parameter that should not be used without a complete understanding of Consul sessions and the implications of their use (it is recommended to leave this blank in nearly all cases). If this parameter is omitted the query will not expire.

stored_token = None

The ACL token to store with the prepared query. This token will be used by default whenever the query is executed.

tags = None

The list of required and/or disallowed tags. If a tag is in this list it must be present. If the tag is preceded with a “!” then it is disallowed.

template = None

Query templating options. This is used to make a single prepared query respond to many different requests.

  • regexp (str) - The regular expression to match with. When using name_prefix_match, this regex is applied against the query name.

  • type (str) - The type of template matching to perform. Currently only name_prefix_match is supported.

token = None

The ACL token to use when saving the prepared query. This overrides the token that the agent provides by default.

static get(resource_name, id, opts=None, connect=None, datacenter=None, dns=None, failover=None, name=None, near=None, only_passing=None, service=None, session=None, stored_token=None, tags=None, template=None, token=None)

Get an existing PreparedQuery resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • connect (pulumi.Input[bool]) – When true the prepared query will return connect proxy services for a queried service. Conditions such as tags in the prepared query will be matched against the proxy service. Defaults to false.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • dns (pulumi.Input[dict]) – Settings for controlling the DNS response details.

  • failover (pulumi.Input[dict]) – Options for controlling behavior when no healthy nodes are available in the local DC.

  • name (pulumi.Input[str]) – The name of the prepared query. Used to identify the prepared query during requests. Can be specified as an empty string to configure the query as a catch-all.

  • near (pulumi.Input[str]) – Allows specifying the name of a node to sort results near using Consul’s distance sorting and network coordinates. The magic _agent value can be used to always sort nearest the node servicing the request.

  • only_passing (pulumi.Input[bool]) – When true, the prepared query will only return nodes with passing health checks in the result.

  • service (pulumi.Input[str]) – The name of the service to query.

  • session (pulumi.Input[str]) – The name of the Consul session to tie this query’s lifetime to. This is an advanced parameter that should not be used without a complete understanding of Consul sessions and the implications of their use (it is recommended to leave this blank in nearly all cases). If this parameter is omitted the query will not expire.

  • stored_token (pulumi.Input[str]) – The ACL token to store with the prepared query. This token will be used by default whenever the query is executed.

  • tags (pulumi.Input[list]) – The list of required and/or disallowed tags. If a tag is in this list it must be present. If the tag is preceded with a “!” then it is disallowed.

  • template (pulumi.Input[dict]) – Query templating options. This is used to make a single prepared query respond to many different requests.

  • token (pulumi.Input[str]) – The ACL token to use when saving the prepared query. This overrides the token that the agent provides by default.

The dns object supports the following:

  • ttl (pulumi.Input[str]) - The TTL to send when returning DNS results.

The failover object supports the following:

  • datacenters (pulumi.Input[list]) - Remote datacenters to return results from.

  • nearestN (pulumi.Input[float]) - Return results from this many datacenters, sorted in ascending order of estimated RTT.

The template object supports the following:

  • regexp (pulumi.Input[str]) - The regular expression to match with. When using name_prefix_match, this regex is applied against the query name.

  • type (pulumi.Input[str]) - The type of template matching to perform. Currently only name_prefix_match is supported.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.Provider(resource_name, opts=None, address=None, ca_file=None, ca_path=None, cert_file=None, datacenter=None, http_auth=None, insecure_https=None, key_file=None, scheme=None, token=None, __props__=None, __name__=None, __opts__=None)

The provider type for the consul package. By default, resources use package-wide configuration settings, however an explicit Provider instance may be created and passed during resource construction to achieve fine-grained programmatic control over provider settings. See the documentation for more information.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

static get(resource_name, id, opts=None)

Get an existing Provider resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

class pulumi_consul.Service(resource_name, opts=None, address=None, checks=None, datacenter=None, external=None, meta=None, name=None, node=None, port=None, service_id=None, tags=None, __props__=None, __name__=None, __opts__=None)

A high-level resource for creating a Service in Consul in the Consul catalog. This is appropriate for registering external services and can be used to create services addressable by Consul that cannot be registered with a local agent.

If the Consul agent is running on the node where this service is registered, it is not recommended to use this resource.

Parameters
  • resource_name (str) – The name of the resource.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the service. Defaults to the address of the node.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • meta (pulumi.Input[dict]) – A map of arbitrary KV metadata linked to the service instance.

  • name (pulumi.Input[str]) – The name of the header.

  • node (pulumi.Input[str]) – The name of the node the to register the service on.

  • port (pulumi.Input[float]) – The port of the service.

  • service_id (pulumi.Input[str]) – The ID of the service.

  • tags (pulumi.Input[list]) – A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

The checks object supports the following:

  • checkId (pulumi.Input[str]) - An ID, unique per agent. Will default to name if not set.

  • deregisterCriticalServiceAfter (pulumi.Input[str]) - The time after which the service is automatically deregistered when in the critical state. Defaults to 30s.

  • headers (pulumi.Input[list]) - The headers to send for an HTTP check. The attributes of each header is given below.

    • name (pulumi.Input[str]) - The name of the header.

    • values (pulumi.Input[list]) - The header’s list of values.

  • http (pulumi.Input[str]) - The HTTP endpoint to call for an HTTP check.

  • interval (pulumi.Input[str]) - The interval to wait between each health-check invocation.

  • method (pulumi.Input[str]) - The method to use for HTTP health-checks. Defaults to GET.

  • name (pulumi.Input[str]) - The name of the header.

  • notes (pulumi.Input[str]) - An opaque field meant to hold human readable text.

  • status (pulumi.Input[str]) - The initial health-check status.

  • tcp (pulumi.Input[str]) - The TCP address and port to connect to for a TCP check.

  • timeout (pulumi.Input[str]) - The timeout value for HTTP checks.

  • tlsSkipVerify (pulumi.Input[bool]) - Whether to deactivate certificate verification for HTTP health-checks. Defaults to false.

address = None

The address of the service. Defaults to the address of the node.

datacenter = None

The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

meta = None

A map of arbitrary KV metadata linked to the service instance.

name = None

The name of the header.

node = None

The name of the node the to register the service on.

port = None

The port of the service.

service_id = None

The ID of the service.

tags = None

A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

static get(resource_name, id, opts=None, address=None, checks=None, datacenter=None, external=None, meta=None, name=None, node=None, port=None, service_id=None, tags=None)

Get an existing Service resource’s state with the given name, id, and optional extra properties used to qualify the lookup.

Parameters
  • resource_name (str) – The unique name of the resulting resource.

  • id (str) – The unique provider ID of the resource to lookup.

  • opts (pulumi.ResourceOptions) – Options for the resource.

  • address (pulumi.Input[str]) – The address of the service. Defaults to the address of the node.

  • datacenter (pulumi.Input[str]) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • meta (pulumi.Input[dict]) – A map of arbitrary KV metadata linked to the service instance.

  • name (pulumi.Input[str]) – The name of the header.

  • node (pulumi.Input[str]) – The name of the node the to register the service on.

  • port (pulumi.Input[float]) – The port of the service.

  • service_id (pulumi.Input[str]) – The ID of the service.

  • tags (pulumi.Input[list]) – A list of values that are opaque to Consul, but can be used to distinguish between services or nodes.

The checks object supports the following:

  • checkId (pulumi.Input[str]) - An ID, unique per agent. Will default to name if not set.

  • deregisterCriticalServiceAfter (pulumi.Input[str]) - The time after which the service is automatically deregistered when in the critical state. Defaults to 30s.

  • headers (pulumi.Input[list]) - The headers to send for an HTTP check. The attributes of each header is given below.

    • name (pulumi.Input[str]) - The name of the header.

    • values (pulumi.Input[list]) - The header’s list of values.

  • http (pulumi.Input[str]) - The HTTP endpoint to call for an HTTP check.

  • interval (pulumi.Input[str]) - The interval to wait between each health-check invocation.

  • method (pulumi.Input[str]) - The method to use for HTTP health-checks. Defaults to GET.

  • name (pulumi.Input[str]) - The name of the header.

  • notes (pulumi.Input[str]) - An opaque field meant to hold human readable text.

  • status (pulumi.Input[str]) - The initial health-check status.

  • tcp (pulumi.Input[str]) - The TCP address and port to connect to for a TCP check.

  • timeout (pulumi.Input[str]) - The timeout value for HTTP checks.

  • tlsSkipVerify (pulumi.Input[bool]) - Whether to deactivate certificate verification for HTTP health-checks. Defaults to false.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters

prop (str) – A property name.

Returns

A potentially transformed property name.

Return type

str

pulumi_consul.get_acl_auth_method(config=None, description=None, name=None, type=None, opts=None)

The .AclAuthMethod data source returns the information related to a Consul Auth Method.

Parameters

name (str) – The name of the ACL Auth Method.

pulumi_consul.get_acl_policy(datacenters=None, description=None, name=None, rules=None, opts=None)

The .AclPolicy data source returns the information related to a Consul ACL Policy.

Parameters

name (str) – The name of the ACL Policy.

pulumi_consul.get_acl_role(description=None, name=None, policies=None, service_identities=None, opts=None)

The .AclRole data source returns the information related to a Consul ACL Role.

Parameters

name (str) – The name of the ACL Role.

The policies object supports the following:

  • id (str)

  • name (str) - The name of the ACL Role.

The service_identities object supports the following:

  • datacenters (list)

  • serviceName (str)

pulumi_consul.get_acl_token(accessor_id=None, description=None, local=None, policies=None, opts=None)

The .AclToken data source returns the information related to the .AclToken resource with the exception of its secret ID.

If you want to get the secret ID associated with a token, use the `.getAclTokenSecretId`` data source <https://www.terraform.io/docs/providers/consul/d/acl_token_secret_id.html>`_.

Parameters

accessor_id (str) – The accessor ID of the ACL token.

The policies object supports the following:

  • id (str)

  • name (str)

pulumi_consul.get_acl_token_secret_id(accessor_id=None, pgp_key=None, opts=None)

Use this data source to access information about an existing resource.

Parameters

accessor_id (str) – The accessor ID of the ACL token.

pulumi_consul.get_agent_config(opts=None)

Note: The .getAgentConfig resource differs from `.getAgentSelf`` <https://www.terraform.io/docs/providers/consul/d/agent_self.html>`_, providing less information but utilizing stable APIs. .getAgentSelf will be deprecated in a future release.

The .getAgentConfig data source returns configuration data from the agent specified in the provider.

pulumi_consul.get_agent_self(opts=None)

Warning: The .getAgentSelf resource has been deprecated and will be removed from a future release of the provider. Read the upgrade instructions for more information.

The .getAgentSelf data source returns configuration and status data from the agent specified in the provider.

pulumi_consul.get_autopilot_health(datacenter=None, opts=None)

The .getAutopilotHealth data source returns autopilot health information about the current Consul cluster.

Parameters

datacenter (str) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

pulumi_consul.get_catalog_nodes(query_options=None, opts=None)

Use this data source to access information about an existing resource.

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str)

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)

pulumi_consul.get_catalog_service(datacenter=None, name=None, query_options=None, tag=None, opts=None)

Use this data source to access information about an existing resource.

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str)

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)

pulumi_consul.get_catalog_services(query_options=None, opts=None)

Use this data source to access information about an existing resource.

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str)

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)

pulumi_consul.get_key_prefix(datacenter=None, path_prefix=None, subkey_collection=None, token=None, opts=None)

Use this data source to access information about an existing resource.

Parameters
  • datacenter (str) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • path_prefix (str) – Specifies the common prefix shared by all keys that will be read by this data source instance. In most cases, this will end with a slash to read a “folder” of subkeys.

  • subkey_collection (list) – Specifies a subkey in Consul to be read. Supported values documented below. Multiple blocks supported.

  • token (str) – The ACL token to use. This overrides the token that the agent provides by default.

The subkey_collection object supports the following:

  • default (str)

  • name (str)

  • path (str)

pulumi_consul.get_keys(datacenter=None, keys=None, token=None, opts=None)

The .Keys resource reads values from the Consul key/value store. This is a powerful way dynamically set values in templates.

Parameters
  • datacenter (str) – The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.

  • keys (list) – Specifies a key in Consul to be read. Supported values documented below. Multiple blocks supported.

  • token (str) – The ACL token to use. This overrides the token that the agent provides by default.

The keys object supports the following:

  • default (str)

  • name (str)

  • path (str)

pulumi_consul.get_nodes(query_options=None, opts=None)

The .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 query_options it is possible to retrieve a list of nodes from a different WAN-attached Consul datacenter.

Parameters

query_options (list) – See below.

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str) - The Consul datacenter to query. Defaults to the same value found in query_options parameter specified below, or if that is empty, the datacenter value found in the Consul agent that this provider is configured to talk to then the datacenter in the provider setup.

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)

pulumi_consul.get_service(datacenter=None, name=None, query_options=None, tag=None, opts=None)

.Service provides details about a specific Consul service in a given datacenter. The results include a list of nodes advertising the specified service, the node’s IP address, port number, node ID, etc. By specifying a different datacenter in the query_options it is possible to retrieve a list of services from a different WAN-attached Consul datacenter.

This data source is different from the .getServices (plural) data source, which provides a summary of the current Consul services.

Parameters
  • datacenter (str) – The Consul datacenter to query. Defaults to the same value found in query_options parameter specified below, or if that is empty, the datacenter value found in the Consul agent that this provider is configured to talk to.

  • name (str) – The service name to select.

  • query_options (list) – See below.

  • tag (str) – A single tag that can be used to filter the list of nodes to return based on a single matching tag..

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str) - The Consul datacenter to query. Defaults to the same value found in query_options parameter specified below, or if that is empty, the datacenter value found in the Consul agent that this provider is configured to talk to.

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)

pulumi_consul.get_service_health(datacenter=None, name=None, near=None, node_meta=None, passing=None, tag=None, wait_for=None, opts=None)

.getServiceHealth can be used to get the list of the instances that are currently healthy, according to their associated health-checks. The result includes the list of service instances, the node associated to each instance and its health-checks.

This resource is likely to change as frequently as the health-checks are being updated, you should expect different results in a frequent basis.

Parameters
  • datacenter (str) – The Consul datacenter to query.

  • name (str) – The service name to select.

  • near (str) – Specifies a node name to sort the node list in ascending order based on the estimated round trip time from that node.

  • node_meta (dict) – Filter the results to nodes with the specified key/value pairs.

  • passing (bool) – Whether to return only nodes with all checks in the passing state. Defaults to true.

  • tag (str) – A single tag that can be used to filter the list to return based on a single matching tag.

pulumi_consul.get_services(query_options=None, opts=None)

The .getServices data source returns a list of Consul services that have been registered with the Consul cluster in a given datacenter. By specifying a different datacenter in the query_options it is possible to retrieve a list of services from a different WAN-attached Consul datacenter.

This data source is different from the .Service (singular) data source, which provides a detailed response about a specific Consul service.

Parameters

query_options (list) – See below.

The query_options object supports the following:

  • allowStale (bool)

  • datacenter (str) - The Consul datacenter to query. Defaults to the same value found in query_options parameter specified below, or if that is empty, the datacenter value found in the Consul agent that this provider is configured to talk to.

  • near (str)

  • nodeMeta (dict)

  • requireConsistent (bool)

  • token (str)

  • waitIndex (float)

  • waitTime (str)