/
pulumi.json
706 lines (706 loc) 路 31.8 KB
/
pulumi.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://github.com/pulumi/pulumi/blob/master/pkg/codegen/schema.json",
"title": "Pulumi Package Metaschema",
"description": "A description of the schema for a Pulumi Package",
"type": "object",
"properties": {
"name": {
"description": "The unqualified name of the package (e.g. \"aws\", \"azure\", \"gcp\", \"kubernetes\", \"random\")",
"type": "string",
"pattern": "^[a-zA-Z][-a-zA-Z0-9_]*$"
},
"displayName": {
"description": "The human-friendly name of the package.",
"type": "string"
},
"version": {
"description": "The version of the package. The version must be valid semver.",
"type": "string",
"pattern": "^v?(?P<major>0|[1-9]\\d*)\\.(?P<minor>0|[1-9]\\d*)\\.(?P<patch>0|[1-9]\\d*)(?:-(?P<prerelease>(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+(?P<buildmetadata>[0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$"
},
"description": {
"description": "The description of the package. Descriptions are interpreted as Markdown.",
"type": "string"
},
"keywords": {
"description": "The list of keywords that are associated with the package, if any.",
"type": "array",
"items": {
"type": "string"
}
},
"homepage": {
"description": "The package's homepage.",
"type": "string"
},
"license": {
"description": "The name of the license used for the package's contents.",
"type": "string"
},
"attribution": {
"description": "Freeform text attribution of derived work, if required.",
"type": "string"
},
"repository": {
"description": "The URL at which the package's sources can be found.",
"type": "string"
},
"logoUrl": {
"description": "The URL of the package's logo, if any.",
"type": "string"
},
"pluginDownloadURL": {
"description": "The URL to use when downloading the provider plugin binary.",
"type": "string"
},
"publisher": {
"description": "The name of the person or organization that authored and published the package.",
"type": "string"
},
"meta": {
"description": "Format metadata about this package.",
"type": "object",
"properties": {
"moduleFormat": {
"description": "A regex that is used by the importer to extract a module name from the module portion of a type token. Packages that use the module format \"namespace1/namespace2/.../namespaceN\" do not need to specify a format. The regex must define one capturing group that contains the module name, which must be formatted as \"namespace1/namespace2/...namespaceN\".",
"type": "string",
"format": "regex"
}
},
"additionalProperties": false,
"required": ["moduleFormat"]
},
"config": {
"description": "The package's configuration variables.",
"type": "object",
"properties": {
"variables": {
"description": "A map from variable name to propertySpec that describes a package's configuration variables.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/propertySpec"
}
},
"required": {
"description": "A list of the names of the package's required configuration variables.",
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false
},
"types": {
"description": "A map from type token to complexTypeSpec that describes the set of complex types (i.e. object, enum) defined by this package.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/complexTypeSpec"
},
"propertyNames": {
"$ref": "#/$defs/token"
}
},
"provider": {
"description": "The provider type for this package.",
"$ref": "#/$defs/resourceSpec"
},
"resources": {
"description": "A map from type token to resourceSpec that describes the set of resources and components defined by this package.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/resourceSpec"
},
"propertyNames": {
"$ref": "#/$defs/token"
}
},
"functions": {
"description": "A map from token to functionSpec that describes the set of functions defined by this package.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/functionSpec"
},
"propertyNames": {
"$ref": "#/$defs/token"
}
},
"language": {
"description": "Additional language-specific data about the package.",
"type": "object"
}
},
"additionalProperties": false,
"required": [
"name"
],
"$defs": {
"token": {
"title": "Token",
"type": "string",
"$comment": "In the regex below, the 'module' portion of the token is optional. However, a missing module component creates a '::', which breaks URNs ('::' is the URN delimiter). We have many test schemas that use an empty module component successfully, as they never create URNs; while these are _probably_ the only places that need updating, it might be possible that there are module-less type tokens in the wild elsewhere and we may need to remain compatible with those tokens.",
"pattern": "^[a-zA-Z][-a-zA-Z0-9_]*:([^0-9][a-zA-Z0-9._/-]*)?:[^0-9][a-zA-Z0-9._/]*$"
},
"schemaStringMap": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"typeSpec": {
"title": "Type Reference",
"description": "A reference to a type. The particular kind of type referenced is determined based on the contents of the \"type\" property and the presence or absence of the \"additionalProperties\", \"items\", \"oneOf\", and \"$ref\" properties.",
"type": "object",
"properties": {
"plain": {
"description": "Indicates that when used as an input, this type does not accept eventual values.",
"type": "boolean"
}
},
"oneOf": [
{
"title": "Primitive Type",
"description": "A reference to a primitive type. A primitive type must have only the \"type\" property set.",
"type": "object",
"properties": {
"type": {
"description": "The primitive type, if any",
"type": "string",
"enum": ["boolean", "integer", "number", "string"]
},
"additionalProperties": false,
"items": false,
"oneOf": false,
"$ref": false
},
"required": ["type"]
},
{
"title": "Array Type",
"description": "A reference to an array type. The \"type\" property must be set to \"array\" and the \"items\" property must be present. No other properties may be present.",
"type": "object",
"$comment": "An array type must have the \"type\" property set.",
"properties": {
"type": {
"const": "array"
},
"items": {
"description": "The element type of the array",
"$ref": "#/$defs/typeSpec"
},
"additionalProperties": false,
"oneOf": false,
"$ref": false
},
"required": ["type", "items"]
},
{
"title": "Map Type",
"description": "A reference to a map type. The \"type\" property must be set to \"object\" and the \"additionalProperties\" property may be present. No other properties may be present.",
"type": "object",
"properties": {
"type": {
"const": "object"
},
"additionalProperties": {
"description": "The element type of the map. Defaults to \"string\" when omitted.",
"$ref": "#/$defs/typeSpec"
},
"items": false,
"oneOf": false,
"$ref": false
},
"required": ["type"]
},
{
"title": "Named Type",
"description": "A reference to a type in this or another document. The \"$ref\" property must be present. The \"type\" property is ignored if it is present. No other properties may be present.",
"type": "object",
"properties": {
"type": {
"description": "ignored; present for compatibility with existing schemas",
"type": "string"
},
"$ref": {
"description": "The URI of the referenced type. For example, the built-in Archive, Asset, and Any\ntypes are referenced as \"pulumi.json#/Archive\", \"pulumi.json#/Asset\", and \"pulumi.json#/Any\", respectively.\nA type from this document is referenced as \"#/types/pulumi:type:token\".\nA type from another document is referenced as \"path#/types/pulumi:type:token\", where path is of the form:\n \"/provider/vX.Y.Z/schema.json\" or \"pulumi.json\" or \"http[s]://example.com/provider/vX.Y.Z/schema.json\"\nA resource from this document is referenced as \"#/resources/pulumi:type:token\".\nA resource from another document is referenced as \"path#/resources/pulumi:type:token\", where path is of the form:\n \"/provider/vX.Y.Z/schema.json\" or \"pulumi.json\" or \"http[s]://example.com/provider/vX.Y.Z/schema.json\"",
"type": "string",
"format": "uri-reference"
},
"additionalProperties": false,
"items": false,
"oneOf": false
},
"required": ["$ref"]
},
{
"title": "Union Type",
"description": "A reference to a union type. The \"oneOf\" property must be present. The union may additional specify an underlying primitive type via the \"type\" property and a discriminator via the \"discriminator\" property. No other properties may be present.",
"type": "object",
"properties": {
"type": {
"description": "The underlying primitive type of the union, if any",
"type": "string",
"enum": ["boolean", "integer", "number", "string"]
},
"oneOf": {
"description": "If present, indicates that values of the type may be one of any of the listed types",
"type": "array",
"items": {
"$ref": "#/$defs/typeSpec"
},
"minItems": 2
},
"discriminator": {
"description": "Informs the consumer of an alternative schema based on the value associated with it",
"type": "object",
"properties": {
"propertyName": {
"description": "PropertyName is the name of the property in the payload that will hold the discriminator value",
"type": "string",
"minLength": 1
},
"mapping": {
"description": "an optional object to hold mappings between payload values and schema names or references",
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"required": [
"propertyName"
]
},
"additionalProperties": false,
"items": false,
"$ref": false
},
"required": ["oneOf"]
}
]
},
"propertySpec": {
"title": "Property Definition",
"description": "Describes an object or resource property",
"type": "object",
"allOf": [
{ "$ref": "#/$defs/typeSpec" }
],
"properties": {
"description": {
"description": "The description of the property, if any. Interpreted as Markdown.",
"type": "string"
},
"const": {
"description": "The constant value for the property, if any. The type of the value must be assignable to the type of the property.",
"type": ["boolean", "number", "string"]
},
"default": {
"description": "The default value for the property, if any. The type of the value must be assignable to the type of the property.",
"type": ["boolean", "number", "string"]
},
"defaultInfo": {
"description": "Additional information about the property's default value, if any.",
"type": "object",
"properties": {
"environment": {
"description": "A set of environment variables to probe for a default value.",
"type": "array",
"items": {
"type": "string"
}
},
"language": {
"description": "Additional language-specific data about the default value.",
"type": "object"
}
},
"required": ["environment"]
},
"deprecationMessage": {
"description": "Indicates whether the property is deprecated",
"type": "string"
},
"language": {
"description": "Additional language-specific data about the property.",
"type": "object"
},
"secret": {
"description": "Specifies whether the property is secret (default false).",
"type": "boolean"
},
"replaceOnChanges": {
"description": "Specifies whether a change to the property causes its containing resource to be replaced instead of updated (default false).",
"type": "boolean"
},
"willReplaceOnChanges": {
"description": "Indicates that the provider will replace the resource when this property is changed.",
"type": "boolean"
}
}
},
"complexTypeSpec": {
"title": "Type Definition",
"description": "Describes an object or enum type.",
"type": "object",
"properties": {
"description": {
"description": "The description of the type, if any. Interpreted as Markdown.",
"type": "string"
},
"language": {
"description": "Additional language-specific data about the type.",
"type": "object"
},
"isOverlay": {
"description": "Indicates that the implementation of the type should not be generated from the schema, and is instead provided out-of-band by the package author",
"type": "boolean"
}
},
"oneOf": [
{
"title": "Object Type Definition",
"type": "object",
"allOf": [
{ "$ref": "#/$defs/objectTypeSpec" }
],
"properties": {
"type": {
"const": "object"
}
}
},
{ "$ref": "#/$defs/enumTypeSpec" }
]
},
"objectTypeSpec": {
"title": "Object Type Details",
"description": "Describes an object type",
"type": "object",
"properties": {
"properties": {
"description": "A map from property name to propertySpec that describes the object's properties.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/propertySpec"
}
},
"required": {
"description": "A list of the names of an object type's required properties. These properties must be set for inputs and will always be set for outputs.",
"type": "array",
"items": {
"type": "string"
}
}
}
},
"enumTypeSpec": {
"title": "Enum Type Definition",
"description": "Describes an enum type",
"type": "object",
"properties" :{
"type": {
"description": "The underlying primitive type of the enum",
"type": "string",
"enum": ["boolean", "integer", "number", "string"]
},
"enum": {
"description": "The list of possible values for the enum",
"type": "array",
"items": {
"title": "Enum Value Definition",
"type": "object",
"properties": {
"name": {
"description": "If present, overrides the name of the enum value that would usually be derived from the value.",
"type": "string"
},
"description": {
"description": "The description of the enum value, if any. Interpreted as Markdown.",
"type": "string"
},
"value": {
"description": "The enum value itself",
"type": ["boolean", "integer", "number", "string"]
},
"deprecationMessage": {
"description": "Indicates whether the value is deprecated.",
"type": "string"
}
},
"required": ["value"]
}
}
},
"required": ["type", "enum"]
},
"resourceSpec": {
"title": "Resource Definition",
"description": "Describes a resource or component.",
"type": "object",
"allOf": [
{ "$ref": "#/$defs/objectTypeSpec" }
],
"properties": {
"description": {
"description": "The description of the resource, if any. Interpreted as Markdown.",
"type": "string"
},
"inputProperties": {
"description": "A map from property name to propertySpec that describes the resource's input properties.",
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/propertySpec"
}
},
"requiredInputs": {
"description": "A list of the names of the resource's required input properties.",
"type": "array",
"items": {
"type": "string"
}
},
"stateInputs": {
"description": "An optional objectTypeSpec that describes additional inputs that mau be necessary to get an existing resource. If this is unset, only an ID is necessary.",
"$ref": "#/$defs/objectTypeSpec"
},
"aliases": {
"description": "The list of aliases for the resource.",
"type": "array",
"items": {
"title": "Alias Definition",
"type": "object",
"properties": {
"name": {
"description": "The name portion of the alias, if any",
"type": "string"
},
"project": {
"description": "The project portion of the alias, if any",
"type": "string"
},
"type": {
"description": "The type portion of the alias, if any",
"type": "string"
}
}
}
},
"deprecationMessage": {
"description": "Indicates whether the resource is deprecated",
"type": "string"
},
"isComponent": {
"description": "Indicates whether the resource is a component.",
"type": "boolean"
},
"methods": {
"description": "A map from method name to function token that describes the resource's method set.",
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"isOverlay": {
"description": "Indicates that the implementation of the resource should not be generated from the schema, and is instead provided out-of-band by the package author",
"type": "boolean"
}
}
},
"functionSpec": {
"title": "Function Definition",
"description": "Describes a function.",
"type": "object",
"properties": {
"description": {
"description": "The description of the function, if any. Interpreted as Markdown.",
"type": "string"
},
"inputs": {
"description": "The bag of input values for the function, if any.",
"$ref": "#/$defs/objectTypeSpec"
},
"multiArgumentInputs": {
"description": "A list of parameter names that determines whether the input bag should be treated as a single argument or as multiple arguments. The list corresponds to the order in which the parameters should be passed to the function.",
"type": "array",
"items": {
"type": "string"
}
},
"outputs": {
"description": "The bag of output values for the function, if any.",
"$ref": "#/$defs/objectTypeSpec"
},
"deprecationMessage": {
"description": "Indicates whether the function is deprecated",
"type": "string"
},
"language": {
"description": "Additional language-specific data about the function.",
"type": "object"
},
"isOverlay": {
"description": "Indicates that the implementation of the function should not be generated from the schema, and is instead provided out-of-band by the package author",
"type": "boolean"
}
}
},
"csharpLanguageSpec": {
"title": "C# Language Overrides Definition",
"description": "Describes C# specific settings",
"type": "object",
"properties": {
"compatibility": {
"description": "",
"type": "string"
},
"namespaces": {
"$ref": "#/$defs/schemaStringMap"
},
"packageReferences": {
"$ref": "#/$defs/schemaStringMap"
},
"rootNamespace": {
"desciption": "Root namespace for the generated .NET SDK"
}
}
},
"goLanguageSpec": {
"title": "Go Language Overrides Definition",
"description": "Describes Go specific settings",
"type": "object",
"properties": {
"generateExtraInputTypes": {
"description": "",
"type": "boolean"
},
"generateResourceContainerTypes": {
"description": "",
"type": "boolean"
},
"importBasePath": {
"description": "Base import path for the Go package",
"type": "string"
}
}
},
"nodejsLanguageSpec": {
"title": "NodeJS Language Overrides Definition",
"description": "Describes NodeJS specific settings",
"type": "object",
"properties": {
"packageName": {
"description": "NPM package name (includes @namespace)",
"type": "string"
},
"packageDescription": {
"description": "NPM package description",
"type": "string"
},
"readme": {
"description": "Content of the generated package README.md file.",
"type": "string"
},
"compatibility": {
"description": "",
"type": "string",
"enum": ["tfbridge20"]
},
"dependencies": {
"description": "NPM package dependencies",
"$ref": "#/$defs/schemaStringMap"
},
"devDependencies": {
"description": "NPM package devDependencies",
"$ref": "#/$defs/schemaStringMap"
},
"disableUnionOutputTypes": {
"description": "",
"type": "boolean"
},
"typescriptVersion": {
"description": "Typescript Version",
"type": "string"
}
}
},
"pythonLanguageSpec": {
"title": "Python Language Overrides Definition",
"description": "Describes Python specific settings",
"type": "object",
"properties": {
"packageName": {
"description": "NPM package name (includes @namespace)",
"type": "string"
},
"readme": {
"description": "Content of the generated package README.md file.",
"type": "string"
},
"compatibility": {
"description": "",
"type": "string",
"enum": ["tfbridge20"]
},
"requires": {
"description": "Python package dependencies for the generated Python SDK",
"$ref": "#/$defs/schemaStringMap"
}
}
},
"javaLanguageSpec": {
"title": "Java Language Overrides Definition",
"description": "Describes Java specific settings",
"type": "object",
"properties": {
"packages": {
"$ref": "#/$defs/schemaStringMap"
},
"basePackage": {
"description": "Base Java package name for the generated Java provider SDK",
"type": "string",
"default": "com.pulumi"
},
"buildFiles": {
"description": "If set to \"gradle\" enables a generation of a basic set of Gradle build files.",
"type": "string"
},
"dependencies": {
"description": "Specifies Maven-style dependencies for the generated code.",
"$ref": "#/$defs/schemaStringMap"
},
"gradleNexusPublishPluginVersion": {
"description": "Enables the use of a given version of io.github.gradle-nexus.publish-plugin in the generated Gradle build files (only when `buildFiles=\"gradle\")",
"type": "string"
},
"gradleTest": {
"description": "generates a test section to enable `gradle test` command to run unit tests over the generated code. Supported values: \"JUnitPlatform\" (only when `buildFiles=\"gradle\")",
"enum": ["JUnitPlatform"]
}
}
},
"languageSpec": {
"title": "Language Overrides Definition",
"description": "Describes programming language specific settings",
"type": "object",
"properties": {
"csharp": {
"$ref": "#/$defs/csharpLanguageSpec"
},
"go": {
"$ref": "#/$defs/goLanguageSpec"
},
"nodejs": {
"$ref": "#/$defs/nodejsLanguageSpec"
},
"python": {
"$ref": "#/$defs/pythonLanguageSpec"
},
"java": {
"$ref": "#/$defs/javaLanguageSpec"
}
}
}
}
}