pulumi-consul 3.11.0a1700198651__tar.gz → 3.11.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/PKG-INFO +1 -1
  2. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/_inputs.py +6 -14
  3. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/_utilities.py +41 -0
  4. pulumi_consul-3.11.1/pulumi_consul/config/__init__.pyi +94 -0
  5. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_keys.py +49 -26
  6. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/outputs.py +6 -14
  7. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul.egg-info/PKG-INFO +2 -2
  8. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul.egg-info/SOURCES.txt +1 -0
  9. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pyproject.toml +1 -1
  10. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/README.md +0 -0
  11. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/__init__.py +0 -0
  12. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_auth_method.py +0 -0
  13. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_binding_rule.py +0 -0
  14. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_policy.py +0 -0
  15. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_role.py +0 -0
  16. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_role_policy_attachment.py +0 -0
  17. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_token.py +0 -0
  18. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_token_policy_attachment.py +0 -0
  19. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/acl_token_role_attachment.py +0 -0
  20. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/admin_partition.py +0 -0
  21. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/agent_service.py +0 -0
  22. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/autopilot_config.py +0 -0
  23. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/catalog_entry.py +0 -0
  24. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/certificate_authority.py +0 -0
  25. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config/__init__.py +0 -0
  26. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config/outputs.py +0 -0
  27. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config/vars.py +0 -0
  28. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry.py +0 -0
  29. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry_service_defaults.py +0 -0
  30. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry_service_intentions.py +0 -0
  31. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry_service_resolver.py +0 -0
  32. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry_service_router.py +0 -0
  33. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/config_entry_service_splitter.py +0 -0
  34. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_acl_auth_method.py +0 -0
  35. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_acl_policy.py +0 -0
  36. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_acl_role.py +0 -0
  37. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_acl_token.py +0 -0
  38. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_acl_token_secret_id.py +0 -0
  39. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_agent_config.py +0 -0
  40. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_agent_self.py +0 -0
  41. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_autopilot_health.py +0 -0
  42. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_catalog_nodes.py +0 -0
  43. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_catalog_service.py +0 -0
  44. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_catalog_services.py +0 -0
  45. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_config_entry.py +0 -0
  46. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_datacenters.py +0 -0
  47. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_key_prefix.py +0 -0
  48. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_network_area_members.py +0 -0
  49. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_network_segments.py +0 -0
  50. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_nodes.py +0 -0
  51. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_peering.py +0 -0
  52. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_peerings.py +0 -0
  53. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_service.py +0 -0
  54. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_service_health.py +0 -0
  55. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/get_services.py +0 -0
  56. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/intention.py +0 -0
  57. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/key_prefix.py +0 -0
  58. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/keys.py +0 -0
  59. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/license.py +0 -0
  60. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/namespace.py +0 -0
  61. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/namespace_policy_attachment.py +0 -0
  62. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/namespace_role_attachment.py +0 -0
  63. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/network_area.py +0 -0
  64. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/node.py +0 -0
  65. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/peering.py +0 -0
  66. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/peering_token.py +0 -0
  67. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/prepared_query.py +0 -0
  68. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/provider.py +0 -0
  69. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/pulumi-plugin.json +0 -0
  70. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/py.typed +0 -0
  71. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul/service.py +0 -0
  72. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul.egg-info/dependency_links.txt +0 -0
  73. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul.egg-info/requires.txt +0 -0
  74. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/pulumi_consul.egg-info/top_level.txt +0 -0
  75. {pulumi_consul-3.11.0a1700198651 → pulumi_consul-3.11.1}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pulumi_consul
3
- Version: 3.11.0a1700198651
3
+ Version: 3.11.1
4
4
  Summary: A Pulumi package for creating and managing consul resources.
5
5
  License: Apache-2.0
6
6
  Project-URL: Homepage, https://pulumi.io
@@ -4671,13 +4671,9 @@ class GetKeysKeyArgs:
4671
4671
  path: str,
4672
4672
  default: Optional[str] = None):
4673
4673
  """
4674
- :param str name: This is the name of the key. This value of the
4675
- key is exposed as `var.<name>`. This is not the path of the key
4676
- in Consul.
4677
- :param str path: This is the path in Consul that should be read
4678
- or written to.
4679
- :param str default: This is the default value to set for `var.<name>`
4680
- if the key does not exist in Consul. Defaults to an empty string.
4674
+ :param str name: This is the name of the key. This value of the key is exposed as `var.<name>`. This is not the path of the key in Consul.
4675
+ :param str path: This is the path in Consul that should be read or written to.
4676
+ :param str default: This is the default value to set for `var.<name>` if the key does not exist in Consul. Defaults to an empty string.
4681
4677
  """
4682
4678
  pulumi.set(__self__, "name", name)
4683
4679
  pulumi.set(__self__, "path", path)
@@ -4688,9 +4684,7 @@ class GetKeysKeyArgs:
4688
4684
  @pulumi.getter
4689
4685
  def name(self) -> str:
4690
4686
  """
4691
- This is the name of the key. This value of the
4692
- key is exposed as `var.<name>`. This is not the path of the key
4693
- in Consul.
4687
+ This is the name of the key. This value of the key is exposed as `var.<name>`. This is not the path of the key in Consul.
4694
4688
  """
4695
4689
  return pulumi.get(self, "name")
4696
4690
 
@@ -4702,8 +4696,7 @@ class GetKeysKeyArgs:
4702
4696
  @pulumi.getter
4703
4697
  def path(self) -> str:
4704
4698
  """
4705
- This is the path in Consul that should be read
4706
- or written to.
4699
+ This is the path in Consul that should be read or written to.
4707
4700
  """
4708
4701
  return pulumi.get(self, "path")
4709
4702
 
@@ -4715,8 +4708,7 @@ class GetKeysKeyArgs:
4715
4708
  @pulumi.getter
4716
4709
  def default(self) -> Optional[str]:
4717
4710
  """
4718
- This is the default value to set for `var.<name>`
4719
- if the key does not exist in Consul. Defaults to an empty string.
4711
+ This is the default value to set for `var.<name>` if the key does not exist in Consul. Defaults to an empty string.
4720
4712
  """
4721
4713
  return pulumi.get(self, "default")
4722
4714
 
@@ -3,6 +3,7 @@
3
3
  # *** Do not edit by hand unless you're certain you know what you are doing! ***
4
4
 
5
5
 
6
+ import asyncio
6
7
  import importlib.util
7
8
  import inspect
8
9
  import json
@@ -13,6 +14,7 @@ import typing
13
14
 
14
15
  import pulumi
15
16
  import pulumi.runtime
17
+ from pulumi.runtime.sync_await import _sync_await
16
18
 
17
19
  from semver import VersionInfo as SemverVersion
18
20
  from parver import Version as PEP440Version
@@ -246,5 +248,44 @@ def lift_output_func(func: typing.Any) -> typing.Callable[[_F], _F]:
246
248
 
247
249
  return (lambda _: lifted_func)
248
250
 
251
+
252
+ def call_plain(
253
+ tok: str,
254
+ props: pulumi.Inputs,
255
+ res: typing.Optional[pulumi.Resource] = None,
256
+ typ: typing.Optional[type] = None,
257
+ ) -> typing.Any:
258
+ """
259
+ Wraps pulumi.runtime.plain to force the output and return it plainly.
260
+ """
261
+
262
+ output = pulumi.runtime.call(tok, props, res, typ)
263
+
264
+ # Ingoring deps silently. They are typically non-empty, r.f() calls include r as a dependency.
265
+ result, known, secret, _ = _sync_await(asyncio.ensure_future(_await_output(output)))
266
+
267
+ problem = None
268
+ if not known:
269
+ problem = ' an unknown value'
270
+ elif secret:
271
+ problem = ' a secret value'
272
+
273
+ if problem:
274
+ raise AssertionError(
275
+ f"Plain resource method '{tok}' incorrectly returned {problem}. "
276
+ + "This is an error in the provider, please report this to the provider developer."
277
+ )
278
+
279
+ return result
280
+
281
+
282
+ async def _await_output(o: pulumi.Output[typing.Any]) -> typing.Tuple[object, bool, bool, set]:
283
+ return (
284
+ await o._future,
285
+ await o._is_known,
286
+ await o._is_secret,
287
+ await o._resources,
288
+ )
289
+
249
290
  def get_plugin_download_url():
250
291
  return None
@@ -0,0 +1,94 @@
1
+ # coding=utf-8
2
+ # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
3
+ # *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+
5
+ import copy
6
+ import warnings
7
+ import pulumi
8
+ import pulumi.runtime
9
+ from typing import Any, Mapping, Optional, Sequence, Union, overload
10
+ from .. import _utilities
11
+ from . import outputs
12
+
13
+ address: Optional[str]
14
+ """
15
+ The HTTP(S) API address of the agent to use. Defaults to "127.0.0.1:8500".
16
+ """
17
+
18
+ authJwt: Optional[str]
19
+ """
20
+ Authenticates to Consul using a JWT authentication method.
21
+ """
22
+
23
+ caFile: Optional[str]
24
+ """
25
+ A path to a PEM-encoded certificate authority used to verify the remote agent's certificate.
26
+ """
27
+
28
+ caPath: Optional[str]
29
+ """
30
+ A path to a directory of PEM-encoded certificate authority files to use to check the authenticity of client and server
31
+ connections. Can also be specified with the `CONSUL_CAPATH` environment variable.
32
+ """
33
+
34
+ caPem: Optional[str]
35
+ """
36
+ PEM-encoded certificate authority used to verify the remote agent's certificate.
37
+ """
38
+
39
+ certFile: Optional[str]
40
+ """
41
+ A path to a PEM-encoded certificate provided to the remote agent; requires use of `key_file` or `key_pem`.
42
+ """
43
+
44
+ certPem: Optional[str]
45
+ """
46
+ PEM-encoded certificate provided to the remote agent; requires use of `key_file` or `key_pem`.
47
+ """
48
+
49
+ datacenter: Optional[str]
50
+ """
51
+ The datacenter to use. Defaults to that of the agent.
52
+ """
53
+
54
+ headers: Optional[str]
55
+ """
56
+ A configuration block, described below, that provides additional headers to be sent along with all requests to the
57
+ Consul server. This block can be specified multiple times.
58
+ """
59
+
60
+ httpAuth: Optional[str]
61
+ """
62
+ HTTP Basic Authentication credentials to be used when communicating with Consul, in the format of either `user` or
63
+ `user:pass`. This may also be specified using the `CONSUL_HTTP_AUTH` environment variable.
64
+ """
65
+
66
+ insecureHttps: Optional[bool]
67
+ """
68
+ Boolean value to disable SSL certificate verification; setting this value to true is not recommended for production use.
69
+ Only use this with scheme set to "https".
70
+ """
71
+
72
+ keyFile: Optional[str]
73
+ """
74
+ A path to a PEM-encoded private key, required if `cert_file` or `cert_pem` is specified.
75
+ """
76
+
77
+ keyPem: Optional[str]
78
+ """
79
+ PEM-encoded private key, required if `cert_file` or `cert_pem` is specified.
80
+ """
81
+
82
+ namespace: Optional[str]
83
+
84
+ scheme: Optional[str]
85
+ """
86
+ The URL scheme of the agent to use ("http" or "https"). Defaults to "http".
87
+ """
88
+
89
+ token: Optional[str]
90
+ """
91
+ The ACL token to use by default when making requests to the agent. Can also be specified with `CONSUL_HTTP_TOKEN` or
92
+ `CONSUL_TOKEN` as an environment variable.
93
+ """
94
+
@@ -23,10 +23,13 @@ class GetKeysResult:
23
23
  """
24
24
  A collection of values returned by getKeys.
25
25
  """
26
- def __init__(__self__, datacenter=None, id=None, keys=None, namespace=None, partition=None, token=None, var=None):
26
+ def __init__(__self__, datacenter=None, error_on_missing_keys=None, id=None, keys=None, namespace=None, partition=None, token=None, var=None):
27
27
  if datacenter and not isinstance(datacenter, str):
28
28
  raise TypeError("Expected argument 'datacenter' to be a str")
29
29
  pulumi.set(__self__, "datacenter", datacenter)
30
+ if error_on_missing_keys and not isinstance(error_on_missing_keys, bool):
31
+ raise TypeError("Expected argument 'error_on_missing_keys' to be a bool")
32
+ pulumi.set(__self__, "error_on_missing_keys", error_on_missing_keys)
30
33
  if id and not isinstance(id, str):
31
34
  raise TypeError("Expected argument 'id' to be a str")
32
35
  pulumi.set(__self__, "id", id)
@@ -50,12 +53,18 @@ class GetKeysResult:
50
53
  @pulumi.getter
51
54
  def datacenter(self) -> str:
52
55
  """
53
- The datacenter the keys are being read from.
54
- * `var.<name>` - For each name given, the corresponding attribute
55
- has the value of the key.
56
+ The datacenter to use. This overrides the agent's default datacenter and the datacenter in the provider setup.
56
57
  """
57
58
  return pulumi.get(self, "datacenter")
58
59
 
60
+ @property
61
+ @pulumi.getter(name="errorOnMissingKeys")
62
+ def error_on_missing_keys(self) -> Optional[bool]:
63
+ """
64
+ Whether to return an error when a key is absent from the KV store and no default is configured. This defaults to `false`.
65
+ """
66
+ return pulumi.get(self, "error_on_missing_keys")
67
+
59
68
  @property
60
69
  @pulumi.getter
61
70
  def id(self) -> str:
@@ -67,21 +76,33 @@ class GetKeysResult:
67
76
  @property
68
77
  @pulumi.getter
69
78
  def keys(self) -> Optional[Sequence['outputs.GetKeysKeyResult']]:
79
+ """
80
+ Specifies a key in Consul to be read. Supported values documented below. Multiple blocks supported.
81
+ """
70
82
  return pulumi.get(self, "keys")
71
83
 
72
84
  @property
73
85
  @pulumi.getter
74
86
  def namespace(self) -> Optional[str]:
87
+ """
88
+ The namespace to lookup the keys.
89
+ """
75
90
  return pulumi.get(self, "namespace")
76
91
 
77
92
  @property
78
93
  @pulumi.getter
79
94
  def partition(self) -> Optional[str]:
95
+ """
96
+ The partition to lookup the keys.
97
+ """
80
98
  return pulumi.get(self, "partition")
81
99
 
82
100
  @property
83
101
  @pulumi.getter
84
102
  def token(self) -> Optional[str]:
103
+ """
104
+ The ACL token to use. This overrides the token that the agent provides by default.
105
+ """
85
106
  warnings.warn("""The token argument has been deprecated and will be removed in a future release.
86
107
  Please use the token argument in the provider configuration""", DeprecationWarning)
87
108
  pulumi.log.warn("""token is deprecated: The token argument has been deprecated and will be removed in a future release.
@@ -92,6 +113,9 @@ Please use the token argument in the provider configuration""")
92
113
  @property
93
114
  @pulumi.getter
94
115
  def var(self) -> Mapping[str, str]:
116
+ """
117
+ For each name given, the corresponding attribute has the value of the key.
118
+ """
95
119
  return pulumi.get(self, "var")
96
120
 
97
121
 
@@ -102,6 +126,7 @@ class AwaitableGetKeysResult(GetKeysResult):
102
126
  yield self
103
127
  return GetKeysResult(
104
128
  datacenter=self.datacenter,
129
+ error_on_missing_keys=self.error_on_missing_keys,
105
130
  id=self.id,
106
131
  keys=self.keys,
107
132
  namespace=self.namespace,
@@ -111,14 +136,14 @@ class AwaitableGetKeysResult(GetKeysResult):
111
136
 
112
137
 
113
138
  def get_keys(datacenter: Optional[str] = None,
139
+ error_on_missing_keys: Optional[bool] = None,
114
140
  keys: Optional[Sequence[pulumi.InputType['GetKeysKeyArgs']]] = None,
115
141
  namespace: Optional[str] = None,
116
142
  partition: Optional[str] = None,
117
143
  token: Optional[str] = None,
118
144
  opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetKeysResult:
119
145
  """
120
- The `Keys` resource reads values from the Consul key/value store.
121
- This is a powerful way dynamically set values in templates.
146
+ The `Keys` datasource reads values from the Consul key/value store. This is a powerful way to dynamically set values in templates.
122
147
 
123
148
  ## Example Usage
124
149
 
@@ -129,27 +154,26 @@ def get_keys(datacenter: Optional[str] = None,
129
154
 
130
155
  app_keys = consul.get_keys(datacenter="nyc1",
131
156
  keys=[consul.GetKeysKeyArgs(
132
- default="ami-1234",
133
157
  name="ami",
134
158
  path="service/app/launch_ami",
135
- )],
136
- token="abcd")
159
+ default="ami-1234",
160
+ )])
137
161
  # Start our instance with the dynamic ami value
138
162
  app_instance = aws.ec2.Instance("appInstance", ami=app_keys.var["ami"])
163
+ # ...
139
164
  ```
140
165
 
141
166
 
142
- :param str datacenter: The datacenter to use. This overrides the
143
- agent's default datacenter and the datacenter in the provider setup.
144
- :param Sequence[pulumi.InputType['GetKeysKeyArgs']] keys: Specifies a key in Consul to be read. Supported
145
- values documented below. Multiple blocks supported.
167
+ :param str datacenter: The datacenter to use. This overrides the agent's default datacenter and the datacenter in the provider setup.
168
+ :param bool error_on_missing_keys: Whether to return an error when a key is absent from the KV store and no default is configured. This defaults to `false`.
169
+ :param Sequence[pulumi.InputType['GetKeysKeyArgs']] keys: Specifies a key in Consul to be read. Supported values documented below. Multiple blocks supported.
146
170
  :param str namespace: The namespace to lookup the keys.
147
171
  :param str partition: The partition to lookup the keys.
148
- :param str token: The ACL token to use. This overrides the
149
- token that the agent provides by default.
172
+ :param str token: The ACL token to use. This overrides the token that the agent provides by default.
150
173
  """
151
174
  __args__ = dict()
152
175
  __args__['datacenter'] = datacenter
176
+ __args__['errorOnMissingKeys'] = error_on_missing_keys
153
177
  __args__['keys'] = keys
154
178
  __args__['namespace'] = namespace
155
179
  __args__['partition'] = partition
@@ -159,6 +183,7 @@ def get_keys(datacenter: Optional[str] = None,
159
183
 
160
184
  return AwaitableGetKeysResult(
161
185
  datacenter=pulumi.get(__ret__, 'datacenter'),
186
+ error_on_missing_keys=pulumi.get(__ret__, 'error_on_missing_keys'),
162
187
  id=pulumi.get(__ret__, 'id'),
163
188
  keys=pulumi.get(__ret__, 'keys'),
164
189
  namespace=pulumi.get(__ret__, 'namespace'),
@@ -169,14 +194,14 @@ def get_keys(datacenter: Optional[str] = None,
169
194
 
170
195
  @_utilities.lift_output_func(get_keys)
171
196
  def get_keys_output(datacenter: Optional[pulumi.Input[Optional[str]]] = None,
197
+ error_on_missing_keys: Optional[pulumi.Input[Optional[bool]]] = None,
172
198
  keys: Optional[pulumi.Input[Optional[Sequence[pulumi.InputType['GetKeysKeyArgs']]]]] = None,
173
199
  namespace: Optional[pulumi.Input[Optional[str]]] = None,
174
200
  partition: Optional[pulumi.Input[Optional[str]]] = None,
175
201
  token: Optional[pulumi.Input[Optional[str]]] = None,
176
202
  opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetKeysResult]:
177
203
  """
178
- The `Keys` resource reads values from the Consul key/value store.
179
- This is a powerful way dynamically set values in templates.
204
+ The `Keys` datasource reads values from the Consul key/value store. This is a powerful way to dynamically set values in templates.
180
205
 
181
206
  ## Example Usage
182
207
 
@@ -187,23 +212,21 @@ def get_keys_output(datacenter: Optional[pulumi.Input[Optional[str]]] = None,
187
212
 
188
213
  app_keys = consul.get_keys(datacenter="nyc1",
189
214
  keys=[consul.GetKeysKeyArgs(
190
- default="ami-1234",
191
215
  name="ami",
192
216
  path="service/app/launch_ami",
193
- )],
194
- token="abcd")
217
+ default="ami-1234",
218
+ )])
195
219
  # Start our instance with the dynamic ami value
196
220
  app_instance = aws.ec2.Instance("appInstance", ami=app_keys.var["ami"])
221
+ # ...
197
222
  ```
198
223
 
199
224
 
200
- :param str datacenter: The datacenter to use. This overrides the
201
- agent's default datacenter and the datacenter in the provider setup.
202
- :param Sequence[pulumi.InputType['GetKeysKeyArgs']] keys: Specifies a key in Consul to be read. Supported
203
- values documented below. Multiple blocks supported.
225
+ :param str datacenter: The datacenter to use. This overrides the agent's default datacenter and the datacenter in the provider setup.
226
+ :param bool error_on_missing_keys: Whether to return an error when a key is absent from the KV store and no default is configured. This defaults to `false`.
227
+ :param Sequence[pulumi.InputType['GetKeysKeyArgs']] keys: Specifies a key in Consul to be read. Supported values documented below. Multiple blocks supported.
204
228
  :param str namespace: The namespace to lookup the keys.
205
229
  :param str partition: The partition to lookup the keys.
206
- :param str token: The ACL token to use. This overrides the
207
- token that the agent provides by default.
230
+ :param str token: The ACL token to use. This overrides the token that the agent provides by default.
208
231
  """
209
232
  ...
@@ -4822,13 +4822,9 @@ class GetKeysKeyResult(dict):
4822
4822
  path: str,
4823
4823
  default: Optional[str] = None):
4824
4824
  """
4825
- :param str name: This is the name of the key. This value of the
4826
- key is exposed as `var.<name>`. This is not the path of the key
4827
- in Consul.
4828
- :param str path: This is the path in Consul that should be read
4829
- or written to.
4830
- :param str default: This is the default value to set for `var.<name>`
4831
- if the key does not exist in Consul. Defaults to an empty string.
4825
+ :param str name: This is the name of the key. This value of the key is exposed as `var.<name>`. This is not the path of the key in Consul.
4826
+ :param str path: This is the path in Consul that should be read or written to.
4827
+ :param str default: This is the default value to set for `var.<name>` if the key does not exist in Consul. Defaults to an empty string.
4832
4828
  """
4833
4829
  pulumi.set(__self__, "name", name)
4834
4830
  pulumi.set(__self__, "path", path)
@@ -4839,9 +4835,7 @@ class GetKeysKeyResult(dict):
4839
4835
  @pulumi.getter
4840
4836
  def name(self) -> str:
4841
4837
  """
4842
- This is the name of the key. This value of the
4843
- key is exposed as `var.<name>`. This is not the path of the key
4844
- in Consul.
4838
+ This is the name of the key. This value of the key is exposed as `var.<name>`. This is not the path of the key in Consul.
4845
4839
  """
4846
4840
  return pulumi.get(self, "name")
4847
4841
 
@@ -4849,8 +4843,7 @@ class GetKeysKeyResult(dict):
4849
4843
  @pulumi.getter
4850
4844
  def path(self) -> str:
4851
4845
  """
4852
- This is the path in Consul that should be read
4853
- or written to.
4846
+ This is the path in Consul that should be read or written to.
4854
4847
  """
4855
4848
  return pulumi.get(self, "path")
4856
4849
 
@@ -4858,8 +4851,7 @@ class GetKeysKeyResult(dict):
4858
4851
  @pulumi.getter
4859
4852
  def default(self) -> Optional[str]:
4860
4853
  """
4861
- This is the default value to set for `var.<name>`
4862
- if the key does not exist in Consul. Defaults to an empty string.
4854
+ This is the default value to set for `var.<name>` if the key does not exist in Consul. Defaults to an empty string.
4863
4855
  """
4864
4856
  return pulumi.get(self, "default")
4865
4857
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
- Name: pulumi-consul
3
- Version: 3.11.0a1700198651
2
+ Name: pulumi_consul
3
+ Version: 3.11.1
4
4
  Summary: A Pulumi package for creating and managing consul resources.
5
5
  License: Apache-2.0
6
6
  Project-URL: Homepage, https://pulumi.io
@@ -68,5 +68,6 @@ pulumi_consul.egg-info/dependency_links.txt
68
68
  pulumi_consul.egg-info/requires.txt
69
69
  pulumi_consul.egg-info/top_level.txt
70
70
  pulumi_consul/config/__init__.py
71
+ pulumi_consul/config/__init__.pyi
71
72
  pulumi_consul/config/outputs.py
72
73
  pulumi_consul/config/vars.py
@@ -5,7 +5,7 @@
5
5
  keywords = ["pulumi", "consul"]
6
6
  readme = "README.md"
7
7
  requires-python = ">=3.7"
8
- version = "3.11.0a1700198651"
8
+ version = "3.11.1"
9
9
  [project.license]
10
10
  text = "Apache-2.0"
11
11
  [project.urls]