@pulumi/consul 3.4.0 → 3.6.0-alpha.1641516994

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 (120) hide show
  1. package/README.md +1 -1
  2. package/aclAuthMethod.js +23 -22
  3. package/aclAuthMethod.js.map +1 -1
  4. package/aclBindingRule.js +15 -14
  5. package/aclBindingRule.js.map +1 -1
  6. package/aclPolicy.js +13 -12
  7. package/aclPolicy.js.map +1 -1
  8. package/aclRole.js +15 -14
  9. package/aclRole.js.map +1 -1
  10. package/aclToken.js +21 -20
  11. package/aclToken.js.map +1 -1
  12. package/aclTokenPolicyAttachment.js +7 -6
  13. package/aclTokenPolicyAttachment.js.map +1 -1
  14. package/aclTokenRoleAttachment.js +7 -6
  15. package/aclTokenRoleAttachment.js.map +1 -1
  16. package/agentService.js +11 -10
  17. package/agentService.js.map +1 -1
  18. package/autopilotConfig.js +19 -18
  19. package/autopilotConfig.js.map +1 -1
  20. package/catalogEntry.js +13 -12
  21. package/catalogEntry.js.map +1 -1
  22. package/certificateAuthority.js +7 -6
  23. package/certificateAuthority.js.map +1 -1
  24. package/config/index.js +11 -4
  25. package/config/index.js.map +1 -1
  26. package/config/vars.d.ts +15 -15
  27. package/config/vars.js +91 -19
  28. package/config/vars.js.map +1 -1
  29. package/configEntry.js +11 -10
  30. package/configEntry.js.map +1 -1
  31. package/getAclAuthMethod.d.ts +14 -0
  32. package/getAclAuthMethod.js +5 -0
  33. package/getAclAuthMethod.js.map +1 -1
  34. package/getAclPolicy.d.ts +26 -0
  35. package/getAclPolicy.js +5 -0
  36. package/getAclPolicy.js.map +1 -1
  37. package/getAclRole.d.ts +14 -0
  38. package/getAclRole.js +5 -0
  39. package/getAclRole.js.map +1 -1
  40. package/getAclToken.d.ts +14 -0
  41. package/getAclToken.js +5 -0
  42. package/getAclToken.js.map +1 -1
  43. package/getAclTokenSecretId.d.ts +15 -0
  44. package/getAclTokenSecretId.js +5 -0
  45. package/getAclTokenSecretId.js.map +1 -1
  46. package/getAgentConfig.js +1 -0
  47. package/getAgentConfig.js.map +1 -1
  48. package/getAgentSelf.js +1 -0
  49. package/getAgentSelf.js.map +1 -1
  50. package/getAutopilotHealth.d.ts +11 -0
  51. package/getAutopilotHealth.js +5 -0
  52. package/getAutopilotHealth.js.map +1 -1
  53. package/getCatalogNodes.d.ts +7 -0
  54. package/getCatalogNodes.js +5 -0
  55. package/getCatalogNodes.js.map +1 -1
  56. package/getCatalogService.d.ts +11 -0
  57. package/getCatalogService.js +5 -0
  58. package/getCatalogService.js.map +1 -1
  59. package/getCatalogServices.d.ts +7 -0
  60. package/getCatalogServices.js +5 -0
  61. package/getCatalogServices.js.map +1 -1
  62. package/getKeyPrefix.d.ts +31 -0
  63. package/getKeyPrefix.js +5 -0
  64. package/getKeyPrefix.js.map +1 -1
  65. package/getKeys.d.ts +25 -0
  66. package/getKeys.js +5 -0
  67. package/getKeys.js.map +1 -1
  68. package/getNetworkAreaMembers.d.ts +24 -4
  69. package/getNetworkAreaMembers.js +9 -4
  70. package/getNetworkAreaMembers.js.map +1 -1
  71. package/getNetworkSegments.d.ts +16 -0
  72. package/getNetworkSegments.js +5 -0
  73. package/getNetworkSegments.js.map +1 -1
  74. package/getNodes.d.ts +10 -0
  75. package/getNodes.js +5 -0
  76. package/getNodes.js.map +1 -1
  77. package/getService.d.ts +31 -0
  78. package/getService.js +5 -0
  79. package/getService.js.map +1 -1
  80. package/getServiceHealth.d.ts +42 -0
  81. package/getServiceHealth.js +5 -0
  82. package/getServiceHealth.js.map +1 -1
  83. package/getServices.d.ts +10 -0
  84. package/getServices.js +5 -0
  85. package/getServices.js.map +1 -1
  86. package/index.js +54 -46
  87. package/index.js.map +1 -1
  88. package/intention.js +19 -18
  89. package/intention.js.map +1 -1
  90. package/keyPrefix.js +15 -14
  91. package/keyPrefix.js.map +1 -1
  92. package/keys.js +13 -12
  93. package/keys.js.map +1 -1
  94. package/license.js +27 -26
  95. package/license.js.map +1 -1
  96. package/namespace.js +13 -12
  97. package/namespace.js.map +1 -1
  98. package/namespacePolicyAttachment.js +7 -6
  99. package/namespacePolicyAttachment.js.map +1 -1
  100. package/namespaceRoleAttachment.js +7 -6
  101. package/namespaceRoleAttachment.js.map +1 -1
  102. package/networkArea.js +13 -12
  103. package/networkArea.js.map +1 -1
  104. package/node.js +13 -12
  105. package/node.js.map +1 -1
  106. package/package.json +4 -3
  107. package/package.json.bak +3 -2
  108. package/package.json.dev +4 -3
  109. package/preparedQuery.js +35 -34
  110. package/preparedQuery.js.map +1 -1
  111. package/provider.js +18 -17
  112. package/provider.js.map +1 -1
  113. package/service.js +27 -26
  114. package/service.js.map +1 -1
  115. package/types/index.js +1 -0
  116. package/types/index.js.map +1 -1
  117. package/types/input.d.ts +200 -0
  118. package/types/output.d.ts +0 -4
  119. package/utilities.js +1 -0
  120. package/utilities.js.map +1 -1
package/types/input.d.ts CHANGED
@@ -77,6 +77,18 @@ export interface CatalogEntryService {
77
77
  */
78
78
  tags?: pulumi.Input<pulumi.Input<string>[]>;
79
79
  }
80
+ export interface GetCatalogNodesQueryOptionArgs {
81
+ allowStale?: pulumi.Input<boolean>;
82
+ datacenter?: pulumi.Input<string>;
83
+ near?: pulumi.Input<string>;
84
+ nodeMeta?: pulumi.Input<{
85
+ [key: string]: pulumi.Input<string>;
86
+ }>;
87
+ requireConsistent?: pulumi.Input<boolean>;
88
+ token?: pulumi.Input<string>;
89
+ waitIndex?: pulumi.Input<number>;
90
+ waitTime?: pulumi.Input<string>;
91
+ }
80
92
  export interface GetCatalogNodesQueryOption {
81
93
  allowStale?: boolean;
82
94
  datacenter?: string;
@@ -89,6 +101,19 @@ export interface GetCatalogNodesQueryOption {
89
101
  waitIndex?: number;
90
102
  waitTime?: string;
91
103
  }
104
+ export interface GetCatalogServiceQueryOptionArgs {
105
+ allowStale?: pulumi.Input<boolean>;
106
+ datacenter?: pulumi.Input<string>;
107
+ namespace?: pulumi.Input<string>;
108
+ near?: pulumi.Input<string>;
109
+ nodeMeta?: pulumi.Input<{
110
+ [key: string]: pulumi.Input<string>;
111
+ }>;
112
+ requireConsistent?: pulumi.Input<boolean>;
113
+ token?: pulumi.Input<string>;
114
+ waitIndex?: pulumi.Input<number>;
115
+ waitTime?: pulumi.Input<string>;
116
+ }
92
117
  export interface GetCatalogServiceQueryOption {
93
118
  allowStale?: boolean;
94
119
  datacenter?: string;
@@ -115,6 +140,38 @@ export interface GetCatalogServicesQueryOption {
115
140
  waitIndex?: number;
116
141
  waitTime?: string;
117
142
  }
143
+ export interface GetCatalogServicesQueryOptionArgs {
144
+ allowStale?: pulumi.Input<boolean>;
145
+ datacenter?: pulumi.Input<string>;
146
+ namespace?: pulumi.Input<string>;
147
+ near?: pulumi.Input<string>;
148
+ nodeMeta?: pulumi.Input<{
149
+ [key: string]: pulumi.Input<string>;
150
+ }>;
151
+ requireConsistent?: pulumi.Input<boolean>;
152
+ token?: pulumi.Input<string>;
153
+ waitIndex?: pulumi.Input<number>;
154
+ waitTime?: pulumi.Input<string>;
155
+ }
156
+ export interface GetKeyPrefixSubkeyCollectionArgs {
157
+ /**
158
+ * This is the default value to set for `var.<name>`
159
+ * if the key does not exist in Consul. Defaults to an empty string.
160
+ */
161
+ default?: pulumi.Input<string>;
162
+ /**
163
+ * This is the name of the key. This value of the
164
+ * key is exposed as `var.<name>`. This is not the path of the subkey
165
+ * in Consul.
166
+ */
167
+ name: pulumi.Input<string>;
168
+ /**
169
+ * This is the subkey path in Consul (which will be appended
170
+ * to the given `pathPrefix`) to construct the full key that will be used
171
+ * to read the value.
172
+ */
173
+ path: pulumi.Input<string>;
174
+ }
118
175
  export interface GetKeyPrefixSubkeyCollection {
119
176
  /**
120
177
  * This is the default value to set for `var.<name>`
@@ -134,6 +191,24 @@ export interface GetKeyPrefixSubkeyCollection {
134
191
  */
135
192
  path: string;
136
193
  }
194
+ export interface GetKeysKeyArgs {
195
+ /**
196
+ * This is the default value to set for `var.<name>`
197
+ * if the key does not exist in Consul. Defaults to an empty string.
198
+ */
199
+ default?: pulumi.Input<string>;
200
+ /**
201
+ * This is the name of the key. This value of the
202
+ * key is exposed as `var.<name>`. This is not the path of the key
203
+ * in Consul.
204
+ */
205
+ name: pulumi.Input<string>;
206
+ /**
207
+ * This is the path in Consul that should be read
208
+ * or written to.
209
+ */
210
+ path: pulumi.Input<string>;
211
+ }
137
212
  export interface GetKeysKey {
138
213
  /**
139
214
  * This is the default value to set for `var.<name>`
@@ -152,6 +227,45 @@ export interface GetKeysKey {
152
227
  */
153
228
  path: string;
154
229
  }
230
+ export interface GetNodesQueryOptionArgs {
231
+ /**
232
+ * When `true`, the default, allow responses from
233
+ * Consul servers that are followers.
234
+ */
235
+ allowStale?: pulumi.Input<boolean>;
236
+ /**
237
+ * The Consul datacenter to query. Defaults to the
238
+ * same value found in `queryOptions` parameter specified below, or if that is
239
+ * empty, the `datacenter` value found in the Consul agent that this provider is
240
+ * configured to talk to then the datacenter in the provider setup.
241
+ */
242
+ datacenter?: pulumi.Input<string>;
243
+ near?: pulumi.Input<string>;
244
+ nodeMeta?: pulumi.Input<{
245
+ [key: string]: pulumi.Input<string>;
246
+ }>;
247
+ /**
248
+ * When `true` force the client to perform a
249
+ * read on at least quorum servers and verify the result is the same. Defaults
250
+ * to `false`.
251
+ */
252
+ requireConsistent?: pulumi.Input<boolean>;
253
+ /**
254
+ * Specify the Consul ACL token to use when performing the
255
+ * request. This defaults to the same API token configured by the `consul`
256
+ * provider but may be overridden if necessary.
257
+ */
258
+ token?: pulumi.Input<string>;
259
+ /**
260
+ * Index number used to enable blocking queries.
261
+ */
262
+ waitIndex?: pulumi.Input<number>;
263
+ /**
264
+ * Max time the client should wait for a blocking query
265
+ * to return.
266
+ */
267
+ waitTime?: pulumi.Input<string>;
268
+ }
155
269
  export interface GetNodesQueryOption {
156
270
  /**
157
271
  * When `true`, the default, allow responses from
@@ -234,6 +348,92 @@ export interface GetServiceQueryOption {
234
348
  */
235
349
  waitTime?: string;
236
350
  }
351
+ export interface GetServiceQueryOptionArgs {
352
+ /**
353
+ * When `true`, the default, allow responses from
354
+ * Consul servers that are followers.
355
+ */
356
+ allowStale?: pulumi.Input<boolean>;
357
+ /**
358
+ * The Consul datacenter to query. Defaults to the
359
+ * same value found in `queryOptions` parameter specified below, or if that is
360
+ * empty, the `datacenter` value found in the Consul agent that this provider is
361
+ * configured to talk to.
362
+ */
363
+ datacenter?: pulumi.Input<string>;
364
+ /**
365
+ * The namespace to lookup the service.
366
+ */
367
+ namespace?: pulumi.Input<string>;
368
+ near?: pulumi.Input<string>;
369
+ nodeMeta?: pulumi.Input<{
370
+ [key: string]: pulumi.Input<string>;
371
+ }>;
372
+ /**
373
+ * When `true` force the client to perform a
374
+ * read on at least quorum servers and verify the result is the same. Defaults
375
+ * to `false`.
376
+ */
377
+ requireConsistent?: pulumi.Input<boolean>;
378
+ /**
379
+ * Specify the Consul ACL token to use when performing the
380
+ * request. This defaults to the same API token configured by the `consul`
381
+ * provider but may be overridden if necessary.
382
+ */
383
+ token?: pulumi.Input<string>;
384
+ /**
385
+ * Index number used to enable blocking queries.
386
+ */
387
+ waitIndex?: pulumi.Input<number>;
388
+ /**
389
+ * Max time the client should wait for a blocking query
390
+ * to return.
391
+ */
392
+ waitTime?: pulumi.Input<string>;
393
+ }
394
+ export interface GetServicesQueryOptionArgs {
395
+ /**
396
+ * When `true`, the default, allow responses from
397
+ * Consul servers that are followers.
398
+ */
399
+ allowStale?: pulumi.Input<boolean>;
400
+ /**
401
+ * The Consul datacenter to query. Defaults to the
402
+ * same value found in `queryOptions` parameter specified below, or if that is
403
+ * empty, the `datacenter` value found in the Consul agent that this provider is
404
+ * configured to talk to.
405
+ */
406
+ datacenter?: pulumi.Input<string>;
407
+ /**
408
+ * The namespace to lookup the services.
409
+ */
410
+ namespace?: pulumi.Input<string>;
411
+ near?: pulumi.Input<string>;
412
+ nodeMeta?: pulumi.Input<{
413
+ [key: string]: pulumi.Input<string>;
414
+ }>;
415
+ /**
416
+ * When `true` force the client to perform a
417
+ * read on at least quorum servers and verify the result is the same. Defaults
418
+ * to `false`.
419
+ */
420
+ requireConsistent?: pulumi.Input<boolean>;
421
+ /**
422
+ * Specify the Consul ACL token to use when performing the
423
+ * request. This defaults to the same API token configured by the `consul`
424
+ * provider but may be overridden if necessary.
425
+ */
426
+ token?: pulumi.Input<string>;
427
+ /**
428
+ * Index number used to enable blocking queries.
429
+ */
430
+ waitIndex?: pulumi.Input<number>;
431
+ /**
432
+ * Max time the client should wait for a blocking query
433
+ * to return.
434
+ */
435
+ waitTime?: pulumi.Input<string>;
436
+ }
237
437
  export interface GetServicesQueryOption {
238
438
  /**
239
439
  * When `true`, the default, allow responses from
package/types/output.d.ts CHANGED
@@ -691,10 +691,6 @@ export interface PreparedQueryTemplate {
691
691
  */
692
692
  type: string;
693
693
  }
694
- export interface ProviderHeader {
695
- name?: string;
696
- value?: string;
697
- }
698
694
  export interface ServiceCheck {
699
695
  /**
700
696
  * An ID, *unique per agent*. Will default to *name*
package/utilities.js CHANGED
@@ -2,6 +2,7 @@
2
2
  // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
3
3
  // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.getVersion = exports.getEnvNumber = exports.getEnvBoolean = exports.getEnv = void 0;
5
6
  function getEnv(...vars) {
6
7
  for (const v of vars) {
7
8
  const value = process.env[v];
package/utilities.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"utilities.js","sourceRoot":"","sources":["../utilities.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;AAGjF,SAAgB,MAAM,CAAC,GAAG,IAAc;IACpC,KAAK,MAAM,CAAC,IAAI,IAAI,EAAE;QAClB,MAAM,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAC7B,IAAI,KAAK,EAAE;YACP,OAAO,KAAK,CAAC;SAChB;KACJ;IACD,OAAO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