-
Notifications
You must be signed in to change notification settings - Fork 50
/
assignment.go
554 lines (494 loc) · 24.1 KB
/
assignment.go
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
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package blueprint
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Manages a Blueprint Assignment resource
//
// > **NOTE:** Azure Blueprints are in Preview and potentially subject to breaking change without notice.
//
// > **NOTE:** Azure Blueprint Assignments can only be applied to Subscriptions. Assignments to Management Groups is not currently supported by the service or by this provider.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/authorization"
// "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/blueprint"
// "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// current, err := core.GetClientConfig(ctx, nil, nil)
// if err != nil {
// return err
// }
// exampleSubscription, err := core.LookupSubscription(ctx, nil, nil)
// if err != nil {
// return err
// }
// exampleDefinition, err := blueprint.GetDefinition(ctx, &blueprint.GetDefinitionArgs{
// Name: "exampleBlueprint",
// ScopeId: exampleSubscription.Id,
// }, nil)
// if err != nil {
// return err
// }
// examplePublishedVersion, err := blueprint.GetPublishedVersion(ctx, &blueprint.GetPublishedVersionArgs{
// ScopeId: exampleDefinition.ScopeId,
// BlueprintName: exampleDefinition.Name,
// Version: "v1.0.0",
// }, nil)
// if err != nil {
// return err
// }
// exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
// Location: pulumi.String("West Europe"),
// Tags: pulumi.StringMap{
// "Environment": pulumi.String("example"),
// },
// })
// if err != nil {
// return err
// }
// exampleUserAssignedIdentity, err := authorization.NewUserAssignedIdentity(ctx, "exampleUserAssignedIdentity", &authorization.UserAssignedIdentityArgs{
// ResourceGroupName: exampleResourceGroup.Name,
// Location: exampleResourceGroup.Location,
// })
// if err != nil {
// return err
// }
// operator, err := authorization.NewAssignment(ctx, "operator", &authorization.AssignmentArgs{
// Scope: *pulumi.String(exampleSubscription.Id),
// RoleDefinitionName: pulumi.String("Blueprint Operator"),
// PrincipalId: exampleUserAssignedIdentity.PrincipalId,
// })
// if err != nil {
// return err
// }
// owner, err := authorization.NewAssignment(ctx, "owner", &authorization.AssignmentArgs{
// Scope: *pulumi.String(exampleSubscription.Id),
// RoleDefinitionName: pulumi.String("Owner"),
// PrincipalId: exampleUserAssignedIdentity.PrincipalId,
// })
// if err != nil {
// return err
// }
// _, err = blueprint.NewAssignment(ctx, "exampleAssignment", &blueprint.AssignmentArgs{
// TargetSubscriptionId: *pulumi.String(exampleSubscription.Id),
// VersionId: *pulumi.String(examplePublishedVersion.Id),
// Location: exampleResourceGroup.Location,
// LockMode: pulumi.String("AllResourcesDoNotDelete"),
// LockExcludePrincipals: pulumi.StringArray{
// *pulumi.String(current.ObjectId),
// },
// Identity: &blueprint.AssignmentIdentityArgs{
// Type: pulumi.String("UserAssigned"),
// IdentityIds: pulumi.StringArray{
// exampleUserAssignedIdentity.ID(),
// },
// },
// ResourceGroups: pulumi.String(` {
// "ResourceGroup": {
// "name": "exampleRG-bp"
// }
// }
//
// `),
//
// ParameterValues: pulumi.String(` {
// "allowedlocationsforresourcegroups_listOfAllowedLocations": {
// "value": ["westus", "westus2", "eastus", "centralus", "centraluseuap", "southcentralus", "northcentralus", "westcentralus", "eastus2", "eastus2euap", "brazilsouth", "brazilus", "northeurope", "westeurope", "eastasia", "southeastasia", "japanwest", "japaneast", "koreacentral", "koreasouth", "indiasouth", "indiawest", "indiacentral", "australiaeast", "australiasoutheast", "canadacentral", "canadaeast", "uknorth", "uksouth2", "uksouth", "ukwest", "francecentral", "francesouth", "australiacentral", "australiacentral2", "uaecentral", "uaenorth", "southafricanorth", "southafricawest", "switzerlandnorth", "switzerlandwest", "germanynorth", "germanywestcentral", "norwayeast", "norwaywest"]
// }
// }
//
// `),
//
// }, pulumi.DependsOn([]pulumi.Resource{
// operator,
// owner,
// }))
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// Azure Blueprint Assignments can be imported using the `resource id`, e.g.
//
// ```sh
// $ pulumi import azure:blueprint/assignment:Assignment example "/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Blueprint/blueprintAssignments/assignSimpleBlueprint"
// ```
type Assignment struct {
pulumi.CustomResourceState
// The name of the blueprint assigned
BlueprintName pulumi.StringOutput `pulumi:"blueprintName"`
// The Description on the Blueprint
Description pulumi.StringOutput `pulumi:"description"`
// The display name of the blueprint
DisplayName pulumi.StringOutput `pulumi:"displayName"`
// An `identity` block as defined below.
Identity AssignmentIdentityOutput `pulumi:"identity"`
// The Azure location of the Assignment. Changing this forces a new resource to be created.
Location pulumi.StringOutput `pulumi:"location"`
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
LockExcludeActions pulumi.StringArrayOutput `pulumi:"lockExcludeActions"`
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
LockExcludePrincipals pulumi.StringArrayOutput `pulumi:"lockExcludePrincipals"`
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
LockMode pulumi.StringPtrOutput `pulumi:"lockMode"`
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
Name pulumi.StringOutput `pulumi:"name"`
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ParameterValues pulumi.StringPtrOutput `pulumi:"parameterValues"`
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ResourceGroups pulumi.StringPtrOutput `pulumi:"resourceGroups"`
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
TargetSubscriptionId pulumi.StringOutput `pulumi:"targetSubscriptionId"`
// Specifies the type of Managed Service Identity that should be configured on this Blueprint. Possible values are `SystemAssigned` and `UserAssigned`.
Type pulumi.StringOutput `pulumi:"type"`
// The ID of the Published Version of the blueprint to be assigned.
VersionId pulumi.StringOutput `pulumi:"versionId"`
}
// NewAssignment registers a new resource with the given unique name, arguments, and options.
func NewAssignment(ctx *pulumi.Context,
name string, args *AssignmentArgs, opts ...pulumi.ResourceOption) (*Assignment, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.Identity == nil {
return nil, errors.New("invalid value for required argument 'Identity'")
}
if args.TargetSubscriptionId == nil {
return nil, errors.New("invalid value for required argument 'TargetSubscriptionId'")
}
if args.VersionId == nil {
return nil, errors.New("invalid value for required argument 'VersionId'")
}
opts = internal.PkgResourceDefaultOpts(opts)
var resource Assignment
err := ctx.RegisterResource("azure:blueprint/assignment:Assignment", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetAssignment gets an existing Assignment resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetAssignment(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *AssignmentState, opts ...pulumi.ResourceOption) (*Assignment, error) {
var resource Assignment
err := ctx.ReadResource("azure:blueprint/assignment:Assignment", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering Assignment resources.
type assignmentState struct {
// The name of the blueprint assigned
BlueprintName *string `pulumi:"blueprintName"`
// The Description on the Blueprint
Description *string `pulumi:"description"`
// The display name of the blueprint
DisplayName *string `pulumi:"displayName"`
// An `identity` block as defined below.
Identity *AssignmentIdentity `pulumi:"identity"`
// The Azure location of the Assignment. Changing this forces a new resource to be created.
Location *string `pulumi:"location"`
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
LockExcludeActions []string `pulumi:"lockExcludeActions"`
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
LockExcludePrincipals []string `pulumi:"lockExcludePrincipals"`
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
LockMode *string `pulumi:"lockMode"`
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
Name *string `pulumi:"name"`
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ParameterValues *string `pulumi:"parameterValues"`
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ResourceGroups *string `pulumi:"resourceGroups"`
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
TargetSubscriptionId *string `pulumi:"targetSubscriptionId"`
// Specifies the type of Managed Service Identity that should be configured on this Blueprint. Possible values are `SystemAssigned` and `UserAssigned`.
Type *string `pulumi:"type"`
// The ID of the Published Version of the blueprint to be assigned.
VersionId *string `pulumi:"versionId"`
}
type AssignmentState struct {
// The name of the blueprint assigned
BlueprintName pulumi.StringPtrInput
// The Description on the Blueprint
Description pulumi.StringPtrInput
// The display name of the blueprint
DisplayName pulumi.StringPtrInput
// An `identity` block as defined below.
Identity AssignmentIdentityPtrInput
// The Azure location of the Assignment. Changing this forces a new resource to be created.
Location pulumi.StringPtrInput
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
LockExcludeActions pulumi.StringArrayInput
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
LockExcludePrincipals pulumi.StringArrayInput
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
LockMode pulumi.StringPtrInput
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
Name pulumi.StringPtrInput
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ParameterValues pulumi.StringPtrInput
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ResourceGroups pulumi.StringPtrInput
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
TargetSubscriptionId pulumi.StringPtrInput
// Specifies the type of Managed Service Identity that should be configured on this Blueprint. Possible values are `SystemAssigned` and `UserAssigned`.
Type pulumi.StringPtrInput
// The ID of the Published Version of the blueprint to be assigned.
VersionId pulumi.StringPtrInput
}
func (AssignmentState) ElementType() reflect.Type {
return reflect.TypeOf((*assignmentState)(nil)).Elem()
}
type assignmentArgs struct {
// An `identity` block as defined below.
Identity AssignmentIdentity `pulumi:"identity"`
// The Azure location of the Assignment. Changing this forces a new resource to be created.
Location *string `pulumi:"location"`
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
LockExcludeActions []string `pulumi:"lockExcludeActions"`
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
LockExcludePrincipals []string `pulumi:"lockExcludePrincipals"`
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
LockMode *string `pulumi:"lockMode"`
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
Name *string `pulumi:"name"`
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ParameterValues *string `pulumi:"parameterValues"`
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ResourceGroups *string `pulumi:"resourceGroups"`
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
TargetSubscriptionId string `pulumi:"targetSubscriptionId"`
// The ID of the Published Version of the blueprint to be assigned.
VersionId string `pulumi:"versionId"`
}
// The set of arguments for constructing a Assignment resource.
type AssignmentArgs struct {
// An `identity` block as defined below.
Identity AssignmentIdentityInput
// The Azure location of the Assignment. Changing this forces a new resource to be created.
Location pulumi.StringPtrInput
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
LockExcludeActions pulumi.StringArrayInput
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
LockExcludePrincipals pulumi.StringArrayInput
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
LockMode pulumi.StringPtrInput
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
Name pulumi.StringPtrInput
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ParameterValues pulumi.StringPtrInput
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
ResourceGroups pulumi.StringPtrInput
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
TargetSubscriptionId pulumi.StringInput
// The ID of the Published Version of the blueprint to be assigned.
VersionId pulumi.StringInput
}
func (AssignmentArgs) ElementType() reflect.Type {
return reflect.TypeOf((*assignmentArgs)(nil)).Elem()
}
type AssignmentInput interface {
pulumi.Input
ToAssignmentOutput() AssignmentOutput
ToAssignmentOutputWithContext(ctx context.Context) AssignmentOutput
}
func (*Assignment) ElementType() reflect.Type {
return reflect.TypeOf((**Assignment)(nil)).Elem()
}
func (i *Assignment) ToAssignmentOutput() AssignmentOutput {
return i.ToAssignmentOutputWithContext(context.Background())
}
func (i *Assignment) ToAssignmentOutputWithContext(ctx context.Context) AssignmentOutput {
return pulumi.ToOutputWithContext(ctx, i).(AssignmentOutput)
}
// AssignmentArrayInput is an input type that accepts AssignmentArray and AssignmentArrayOutput values.
// You can construct a concrete instance of `AssignmentArrayInput` via:
//
// AssignmentArray{ AssignmentArgs{...} }
type AssignmentArrayInput interface {
pulumi.Input
ToAssignmentArrayOutput() AssignmentArrayOutput
ToAssignmentArrayOutputWithContext(context.Context) AssignmentArrayOutput
}
type AssignmentArray []AssignmentInput
func (AssignmentArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Assignment)(nil)).Elem()
}
func (i AssignmentArray) ToAssignmentArrayOutput() AssignmentArrayOutput {
return i.ToAssignmentArrayOutputWithContext(context.Background())
}
func (i AssignmentArray) ToAssignmentArrayOutputWithContext(ctx context.Context) AssignmentArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(AssignmentArrayOutput)
}
// AssignmentMapInput is an input type that accepts AssignmentMap and AssignmentMapOutput values.
// You can construct a concrete instance of `AssignmentMapInput` via:
//
// AssignmentMap{ "key": AssignmentArgs{...} }
type AssignmentMapInput interface {
pulumi.Input
ToAssignmentMapOutput() AssignmentMapOutput
ToAssignmentMapOutputWithContext(context.Context) AssignmentMapOutput
}
type AssignmentMap map[string]AssignmentInput
func (AssignmentMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Assignment)(nil)).Elem()
}
func (i AssignmentMap) ToAssignmentMapOutput() AssignmentMapOutput {
return i.ToAssignmentMapOutputWithContext(context.Background())
}
func (i AssignmentMap) ToAssignmentMapOutputWithContext(ctx context.Context) AssignmentMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(AssignmentMapOutput)
}
type AssignmentOutput struct{ *pulumi.OutputState }
func (AssignmentOutput) ElementType() reflect.Type {
return reflect.TypeOf((**Assignment)(nil)).Elem()
}
func (o AssignmentOutput) ToAssignmentOutput() AssignmentOutput {
return o
}
func (o AssignmentOutput) ToAssignmentOutputWithContext(ctx context.Context) AssignmentOutput {
return o
}
// The name of the blueprint assigned
func (o AssignmentOutput) BlueprintName() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.BlueprintName }).(pulumi.StringOutput)
}
// The Description on the Blueprint
func (o AssignmentOutput) Description() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.Description }).(pulumi.StringOutput)
}
// The display name of the blueprint
func (o AssignmentOutput) DisplayName() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.DisplayName }).(pulumi.StringOutput)
}
// An `identity` block as defined below.
func (o AssignmentOutput) Identity() AssignmentIdentityOutput {
return o.ApplyT(func(v *Assignment) AssignmentIdentityOutput { return v.Identity }).(AssignmentIdentityOutput)
}
// The Azure location of the Assignment. Changing this forces a new resource to be created.
func (o AssignmentOutput) Location() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.Location }).(pulumi.StringOutput)
}
// a list of up to 200 actions that are permitted to bypass the locks applied by the Blueprint.
func (o AssignmentOutput) LockExcludeActions() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringArrayOutput { return v.LockExcludeActions }).(pulumi.StringArrayOutput)
}
// a list of up to 5 Principal IDs that are permitted to bypass the locks applied by the Blueprint.
func (o AssignmentOutput) LockExcludePrincipals() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringArrayOutput { return v.LockExcludePrincipals }).(pulumi.StringArrayOutput)
}
// The locking mode of the Blueprint Assignment. One of `None` (Default), `AllResourcesReadOnly`, or `AllResourcesDoNotDelete`. Defaults to `None`.
func (o AssignmentOutput) LockMode() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringPtrOutput { return v.LockMode }).(pulumi.StringPtrOutput)
}
// The name of the Blueprint Assignment. Changing this forces a new resource to be created.
func (o AssignmentOutput) Name() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)
}
// a JSON string to supply Blueprint Assignment parameter values.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
func (o AssignmentOutput) ParameterValues() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringPtrOutput { return v.ParameterValues }).(pulumi.StringPtrOutput)
}
// a JSON string to supply the Blueprint Resource Group information.
//
// > **NOTE:** Improperly formatted JSON, or missing values required by a Blueprint will cause the assignment to fail.
func (o AssignmentOutput) ResourceGroups() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringPtrOutput { return v.ResourceGroups }).(pulumi.StringPtrOutput)
}
// The Subscription ID the Blueprint Published Version is to be applied to. Changing this forces a new resource to be created.
func (o AssignmentOutput) TargetSubscriptionId() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.TargetSubscriptionId }).(pulumi.StringOutput)
}
// Specifies the type of Managed Service Identity that should be configured on this Blueprint. Possible values are `SystemAssigned` and `UserAssigned`.
func (o AssignmentOutput) Type() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.Type }).(pulumi.StringOutput)
}
// The ID of the Published Version of the blueprint to be assigned.
func (o AssignmentOutput) VersionId() pulumi.StringOutput {
return o.ApplyT(func(v *Assignment) pulumi.StringOutput { return v.VersionId }).(pulumi.StringOutput)
}
type AssignmentArrayOutput struct{ *pulumi.OutputState }
func (AssignmentArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Assignment)(nil)).Elem()
}
func (o AssignmentArrayOutput) ToAssignmentArrayOutput() AssignmentArrayOutput {
return o
}
func (o AssignmentArrayOutput) ToAssignmentArrayOutputWithContext(ctx context.Context) AssignmentArrayOutput {
return o
}
func (o AssignmentArrayOutput) Index(i pulumi.IntInput) AssignmentOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Assignment {
return vs[0].([]*Assignment)[vs[1].(int)]
}).(AssignmentOutput)
}
type AssignmentMapOutput struct{ *pulumi.OutputState }
func (AssignmentMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Assignment)(nil)).Elem()
}
func (o AssignmentMapOutput) ToAssignmentMapOutput() AssignmentMapOutput {
return o
}
func (o AssignmentMapOutput) ToAssignmentMapOutputWithContext(ctx context.Context) AssignmentMapOutput {
return o
}
func (o AssignmentMapOutput) MapIndex(k pulumi.StringInput) AssignmentOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Assignment {
return vs[0].(map[string]*Assignment)[vs[1].(string)]
}).(AssignmentOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*AssignmentInput)(nil)).Elem(), &Assignment{})
pulumi.RegisterInputType(reflect.TypeOf((*AssignmentArrayInput)(nil)).Elem(), AssignmentArray{})
pulumi.RegisterInputType(reflect.TypeOf((*AssignmentMapInput)(nil)).Elem(), AssignmentMap{})
pulumi.RegisterOutputType(AssignmentOutput{})
pulumi.RegisterOutputType(AssignmentArrayOutput{})
pulumi.RegisterOutputType(AssignmentMapOutput{})
}