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.
Create Provider Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Provider(name: string, args?: ProviderArgs, opts?: CustomResourceOptions);@overload
def Provider(resource_name: str,
args: Optional[ProviderArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Provider(resource_name: str,
opts: Optional[ResourceOptions] = None,
address: Optional[str] = None,
auth_jwt: Optional[ProviderAuthJwtArgs] = None,
auth_login_aws: Optional[ProviderAuthLoginAwsArgs] = None,
ca_file: Optional[str] = None,
ca_path: Optional[str] = None,
ca_pem: Optional[str] = None,
cert_file: Optional[str] = None,
cert_pem: Optional[str] = None,
datacenter: Optional[str] = None,
headers: Optional[Sequence[ProviderHeaderArgs]] = None,
http_auth: Optional[str] = None,
insecure_https: Optional[bool] = None,
key_file: Optional[str] = None,
key_pem: Optional[str] = None,
namespace: Optional[str] = None,
scheme: Optional[str] = None,
token: Optional[str] = None)func NewProvider(ctx *Context, name string, args *ProviderArgs, opts ...ResourceOption) (*Provider, error)public Provider(string name, ProviderArgs? args = null, CustomResourceOptions? opts = null)
public Provider(String name, ProviderArgs args)
public Provider(String name, ProviderArgs args, CustomResourceOptions options)
type: pulumi:providers:consul
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ProviderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ProviderArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ProviderArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ProviderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ProviderArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Provider Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Provider resource accepts the following input properties:
- Address string
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- Auth
Jwt ProviderAuth Jwt - Authenticates to Consul using a JWT authentication method.
- Auth
Login ProviderAws Auth Login Aws - Login to Consul using the AWS IAM auth method
- Ca
File string - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- Ca
Path string - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - Ca
Pem string - PEM-encoded certificate authority used to verify the remote agent's certificate.
- Cert
File string - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - Cert
Pem string - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - Datacenter string
- The datacenter to use. Defaults to that of the agent.
- Headers
List<Provider
Header> - A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- Http
Auth string - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - Insecure
Https bool - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- Key
File string - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - Key
Pem string - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - Namespace string
- Scheme string
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- Token string
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
- Address string
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- Auth
Jwt ProviderAuth Jwt Args - Authenticates to Consul using a JWT authentication method.
- Auth
Login ProviderAws Auth Login Aws Args - Login to Consul using the AWS IAM auth method
- Ca
File string - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- Ca
Path string - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - Ca
Pem string - PEM-encoded certificate authority used to verify the remote agent's certificate.
- Cert
File string - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - Cert
Pem string - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - Datacenter string
- The datacenter to use. Defaults to that of the agent.
- Headers
[]Provider
Header Args - A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- Http
Auth string - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - Insecure
Https bool - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- Key
File string - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - Key
Pem string - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - Namespace string
- Scheme string
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- Token string
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
- address String
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- auth
Jwt ProviderAuth Jwt - Authenticates to Consul using a JWT authentication method.
- auth
Login ProviderAws Auth Login Aws - Login to Consul using the AWS IAM auth method
- ca
File String - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- ca
Path String - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - ca
Pem String - PEM-encoded certificate authority used to verify the remote agent's certificate.
- cert
File String - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - cert
Pem String - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - datacenter String
- The datacenter to use. Defaults to that of the agent.
- headers
List<Provider
Header> - A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- http
Auth String - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - insecure
Https Boolean - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- key
File String - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - key
Pem String - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - namespace String
- scheme String
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- token String
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
- address string
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- auth
Jwt ProviderAuth Jwt - Authenticates to Consul using a JWT authentication method.
- auth
Login ProviderAws Auth Login Aws - Login to Consul using the AWS IAM auth method
- ca
File string - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- ca
Path string - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - ca
Pem string - PEM-encoded certificate authority used to verify the remote agent's certificate.
- cert
File string - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - cert
Pem string - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - datacenter string
- The datacenter to use. Defaults to that of the agent.
- headers
Provider
Header[] - A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- http
Auth string - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - insecure
Https boolean - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- key
File string - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - key
Pem string - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - namespace string
- scheme string
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- token string
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
- address str
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- auth_
jwt ProviderAuth Jwt Args - Authenticates to Consul using a JWT authentication method.
- auth_
login_ Provideraws Auth Login Aws Args - Login to Consul using the AWS IAM auth method
- ca_
file str - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- ca_
path str - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - ca_
pem str - PEM-encoded certificate authority used to verify the remote agent's certificate.
- cert_
file str - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - cert_
pem str - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - datacenter str
- The datacenter to use. Defaults to that of the agent.
- headers
Sequence[Provider
Header Args] - A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- http_
auth str - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - insecure_
https bool - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- key_
file str - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - key_
pem str - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - namespace str
- scheme str
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- token str
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
- address String
- The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
- auth
Jwt Property Map - Authenticates to Consul using a JWT authentication method.
- auth
Login Property MapAws - Login to Consul using the AWS IAM auth method
- ca
File String - A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
- ca
Path String - A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server connections. Can also be specified with the
CONSUL_CAPATHenvironment variable. - ca
Pem String - PEM-encoded certificate authority used to verify the remote agent's certificate.
- cert
File String - A path to a PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - cert
Pem String - PEM-encoded certificate provided to the remote agent; requires use of
key_fileorkey_pem. - datacenter String
- The datacenter to use. Defaults to that of the agent.
- headers List<Property Map>
- A configuration block, described below, that provides additional headers to be sent along with all requests to the Consul server. This block can be specified multiple times.
- http
Auth String - HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either
useroruser:pass. This may also be specified using theCONSUL_HTTP_AUTHenvironment variable. - insecure
Https Boolean - Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use. Only use this with scheme set to "https".
- key
File String - A path to a PEM-encoded private key, required if
cert_fileorcert_pemis specified. - key
Pem String - PEM-encoded private key, required if
cert_fileorcert_pemis specified. - namespace String
- scheme String
- The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
- token String
- The ACL token to use by default when making requests to the agent. Can also be specified with
CONSUL_HTTP_TOKENorCONSUL_TOKENas an environment variable.
Outputs
All input properties are implicitly available as output properties. Additionally, the Provider resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Provider Resource Methods
TerraformConfig Method
This function returns a Terraform config object with terraform-namecased keys,to be used with the Terraform Module Provider.
Using TerraformConfig
terraformConfig(): Output<Provider.TerraformConfigResult>def terraform_config() -> Output[Provider.Terraform_configResult]func (r *Provider) TerraformConfig() (ProviderTerraformConfigResultOutput, error)public Output<Provider.TerraformConfigResult> TerraformConfig()TerraformConfig Result
- Result Dictionary<string, object>
- Result map[string]interface{}
- result Map<String,Object>
- result {[key: string]: any}
- result Mapping[str, Any]
- result Map<Any>
Supporting Types
ProviderAuthJwt, ProviderAuthJwtArgs
- Auth
Method string - The name of the auth method to use for login.
- Bearer
Token string - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- Meta Dictionary<string, string>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- Use
Terraform boolCloud Workload Identity
- Auth
Method string - The name of the auth method to use for login.
- Bearer
Token string - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- Meta map[string]string
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- Use
Terraform boolCloud Workload Identity
- auth
Method String - The name of the auth method to use for login.
- bearer
Token String - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- meta Map<String,String>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- use
Terraform BooleanCloud Workload Identity
- auth
Method string - The name of the auth method to use for login.
- bearer
Token string - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- meta {[key: string]: string}
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- use
Terraform booleanCloud Workload Identity
- auth_
method str - The name of the auth method to use for login.
- bearer_
token str - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- meta Mapping[str, str]
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- use_
terraform_ boolcloud_ workload_ identity
- auth
Method String - The name of the auth method to use for login.
- bearer
Token String - The bearer token to present to the auth method during login for authentication purposes. For the Kubernetes auth method this is a Service Account Token (JWT).
- meta Map<String>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- use
Terraform BooleanCloud Workload Identity
ProviderAuthLoginAws, ProviderAuthLoginAwsArgs
- Auth
Method string - The name of the Consul auth method to use for login.
- Aws
Access stringKey Id - The AWS access key ID.
- Aws
Iam stringEndpoint - The IAM endpoint URL.
- Aws
Profile string - The name of the AWS profile.
- Aws
Region string - The AWS region.
- Aws
Role stringArn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- Aws
Role stringSession Name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- Aws
Secret stringAccess Key - The AWS secret access key.
- Aws
Session stringToken - The AWS session token.
- string
- Path to the AWS shared credentials file.
- Aws
Sts stringEndpoint - The STS endpoint URL.
- Aws
Web stringIdentity Token File - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- Meta Dictionary<string, string>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- Namespace string
- The Consul namespace to authenticate to.
- Partition string
- The Consul admin partition to authenticate to.
- Server
Id stringHeader Value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
- Auth
Method string - The name of the Consul auth method to use for login.
- Aws
Access stringKey Id - The AWS access key ID.
- Aws
Iam stringEndpoint - The IAM endpoint URL.
- Aws
Profile string - The name of the AWS profile.
- Aws
Region string - The AWS region.
- Aws
Role stringArn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- Aws
Role stringSession Name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- Aws
Secret stringAccess Key - The AWS secret access key.
- Aws
Session stringToken - The AWS session token.
- string
- Path to the AWS shared credentials file.
- Aws
Sts stringEndpoint - The STS endpoint URL.
- Aws
Web stringIdentity Token File - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- Meta map[string]string
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- Namespace string
- The Consul namespace to authenticate to.
- Partition string
- The Consul admin partition to authenticate to.
- Server
Id stringHeader Value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
- auth
Method String - The name of the Consul auth method to use for login.
- aws
Access StringKey Id - The AWS access key ID.
- aws
Iam StringEndpoint - The IAM endpoint URL.
- aws
Profile String - The name of the AWS profile.
- aws
Region String - The AWS region.
- aws
Role StringArn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- aws
Role StringSession Name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- aws
Secret StringAccess Key - The AWS secret access key.
- aws
Session StringToken - The AWS session token.
- String
- Path to the AWS shared credentials file.
- aws
Sts StringEndpoint - The STS endpoint URL.
- aws
Web StringIdentity Token File - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- meta Map<String,String>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- namespace String
- The Consul namespace to authenticate to.
- partition String
- The Consul admin partition to authenticate to.
- server
Id StringHeader Value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
- auth
Method string - The name of the Consul auth method to use for login.
- aws
Access stringKey Id - The AWS access key ID.
- aws
Iam stringEndpoint - The IAM endpoint URL.
- aws
Profile string - The name of the AWS profile.
- aws
Region string - The AWS region.
- aws
Role stringArn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- aws
Role stringSession Name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- aws
Secret stringAccess Key - The AWS secret access key.
- aws
Session stringToken - The AWS session token.
- string
- Path to the AWS shared credentials file.
- aws
Sts stringEndpoint - The STS endpoint URL.
- aws
Web stringIdentity Token File - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- meta {[key: string]: string}
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- namespace string
- The Consul namespace to authenticate to.
- partition string
- The Consul admin partition to authenticate to.
- server
Id stringHeader Value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
- auth_
method str - The name of the Consul auth method to use for login.
- aws_
access_ strkey_ id - The AWS access key ID.
- aws_
iam_ strendpoint - The IAM endpoint URL.
- aws_
profile str - The name of the AWS profile.
- aws_
region str - The AWS region.
- aws_
role_ strarn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- aws_
role_ strsession_ name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- aws_
secret_ straccess_ key - The AWS secret access key.
- aws_
session_ strtoken - The AWS session token.
- str
- Path to the AWS shared credentials file.
- aws_
sts_ strendpoint - The STS endpoint URL.
- aws_
web_ stridentity_ token_ file - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- meta Mapping[str, str]
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- namespace str
- The Consul namespace to authenticate to.
- partition str
- The Consul admin partition to authenticate to.
- server_
id_ strheader_ value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
- auth
Method String - The name of the Consul auth method to use for login.
- aws
Access StringKey Id - The AWS access key ID.
- aws
Iam StringEndpoint - The IAM endpoint URL.
- aws
Profile String - The name of the AWS profile.
- aws
Region String - The AWS region.
- aws
Role StringArn - The ARN of the AWS Role to assume. Used during STS AssumeRole
- aws
Role StringSession Name - Specifies the name to attach to the AWS role session. Used during STS AssumeRole
- aws
Secret StringAccess Key - The AWS secret access key.
- aws
Session StringToken - The AWS session token.
- String
- Path to the AWS shared credentials file.
- aws
Sts StringEndpoint - The STS endpoint URL.
- aws
Web StringIdentity Token File - Path to the file containing an OAuth 2.0 access token or OpenID Connect ID token.
- meta Map<String>
- Specifies arbitrary KV metadata linked to the token. Can be useful to track origins.
- namespace String
- The Consul namespace to authenticate to.
- partition String
- The Consul admin partition to authenticate to.
- server
Id StringHeader Value - The Consul Server ID header value to include in the STS signing request. This must match the ServerIDHeaderValue configured in the Consul auth method.
ProviderHeader, ProviderHeaderArgs
Package Details
- Repository
- HashiCorp Consul pulumi/pulumi-consul
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
consulTerraform Provider.
