generated from pulumi/pulumi-tf-provider-boilerplate
/
integrationRegistry.go
681 lines (608 loc) · 32.7 KB
/
integrationRegistry.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
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
// 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 aquasec
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-aquasec/sdk/go/aquasec/internal"
)
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
// "github.com/pulumiverse/pulumi-aquasec/sdk/go/aquasec"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := aquasec.NewIntegrationRegistry(ctx, "integrationRegistry", &aquasec.IntegrationRegistryArgs{
// AdvancedSettingsCleanup: pulumi.Bool(false),
// AlwaysPullPatterns: pulumi.StringArray{
// pulumi.String(":latest"),
// pulumi.String(":v1"),
// },
// Author: pulumi.String("aqua@aquasec.com"),
// AutoCleanup: pulumi.Bool(false),
// AutoPull: pulumi.Bool(true),
// AutoPullInterval: pulumi.Int(1),
// AutoPullMax: pulumi.Int(100),
// AutoPullRescan: pulumi.Bool(false),
// AutoPullTime: pulumi.String("08:45"),
// Description: pulumi.String("Automatically discovered registry"),
// ImageCreationDateCondition: pulumi.String("image_count"),
// Options: aquasec.IntegrationRegistryOptionArray{
// &aquasec.IntegrationRegistryOptionArgs{
// Option: pulumi.String("ARNRole"),
// Value: pulumi.String("arn:aws:iam::111111111111:role/terraform"),
// },
// &aquasec.IntegrationRegistryOptionArgs{
// Option: pulumi.String("sts:ExternalId"),
// Value: pulumi.String("test1-test2-test3"),
// },
// &aquasec.IntegrationRegistryOptionArgs{
// Option: pulumi.String("TestImagePull"),
// Value: pulumi.String("nginx:latest"),
// },
// },
// Password: pulumi.String(""),
// Prefixes: pulumi.StringArray{
// pulumi.String("111111111111.dkr.ecr.us-east-1.amazonaws.com"),
// },
// PullImageAge: pulumi.String("0D"),
// PullImageCount: pulumi.Int(3),
// PullImageTagPatterns: pulumi.StringArray{
// pulumi.String(":Latest"),
// pulumi.String(":latest"),
// },
// PullRepoPatternsExcludeds: pulumi.StringArray{
// pulumi.String(":xyz"),
// pulumi.String(":onlytest"),
// },
// ScannerNames: pulumi.StringArray{},
// ScannerType: pulumi.String("any"),
// Type: pulumi.String("AWS"),
// Url: pulumi.String("us-east-1"),
// Username: pulumi.String(""),
// Webhooks: aquasec.IntegrationRegistryWebhookArray{
// &aquasec.IntegrationRegistryWebhookArgs{
// AuthToken: pulumi.String("test1-test2-test3"),
// Enabled: pulumi.Bool(true),
// UnQuarantine: pulumi.Bool(false),
// Url: pulumi.String("https://aquasec.com/"),
// },
// },
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
type IntegrationRegistry struct {
pulumi.CustomResourceState
// Automatically clean up that don't match the pull criteria
AdvancedSettingsCleanup pulumi.BoolPtrOutput `pulumi:"advancedSettingsCleanup"`
// List of image patterns to pull always
AlwaysPullPatterns pulumi.StringArrayOutput `pulumi:"alwaysPullPatterns"`
// The username of the user who created or last modified the registry
Author pulumi.StringOutput `pulumi:"author"`
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
AutoCleanup pulumi.BoolPtrOutput `pulumi:"autoCleanup"`
// Whether to automatically pull images from the registry on creation and daily
AutoPull pulumi.BoolPtrOutput `pulumi:"autoPull"`
// The interval in days to start pulling new images from the registry, Defaults to 1
AutoPullInterval pulumi.IntPtrOutput `pulumi:"autoPullInterval"`
// Maximum number of repositories to pull every day, defaults to 100
AutoPullMax pulumi.IntPtrOutput `pulumi:"autoPullMax"`
// Whether to automatically pull and rescan images from the registry on creation and daily
AutoPullRescan pulumi.BoolPtrOutput `pulumi:"autoPullRescan"`
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
AutoPullTime pulumi.StringPtrOutput `pulumi:"autoPullTime"`
// The description of the registry
Description pulumi.StringPtrOutput `pulumi:"description"`
// Additional condition for pulling and rescanning images, Defaults to 'none'
ImageCreationDateCondition pulumi.StringOutput `pulumi:"imageCreationDateCondition"`
// The last time the registry was modified in UNIX time
Lastupdate pulumi.IntOutput `pulumi:"lastupdate"`
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
Name pulumi.StringOutput `pulumi:"name"`
Options IntegrationRegistryOptionArrayOutput `pulumi:"options"`
// The password for registry authentication
Password pulumi.StringPtrOutput `pulumi:"password"`
// List of possible prefixes to image names pulled from the registry
Prefixes pulumi.StringArrayOutput `pulumi:"prefixes"`
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
PullImageAge pulumi.StringOutput `pulumi:"pullImageAge"`
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
PullImageCount pulumi.IntOutput `pulumi:"pullImageCount"`
// List of image tags patterns to pull
PullImageTagPatterns pulumi.StringArrayOutput `pulumi:"pullImageTagPatterns"`
// List of image patterns to exclude
PullRepoPatternsExcludeds pulumi.StringArrayOutput `pulumi:"pullRepoPatternsExcludeds"`
// Registry scan timeout in Minutes
RegistryScanTimeout pulumi.IntPtrOutput `pulumi:"registryScanTimeout"`
// List of scanner names
ScannerNames pulumi.StringArrayOutput `pulumi:"scannerNames"`
// The Scanner type
ScannerType pulumi.StringOutput `pulumi:"scannerType"`
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
Type pulumi.StringOutput `pulumi:"type"`
// The URL, address or region of the registry
Url pulumi.StringOutput `pulumi:"url"`
// The username for registry authentication.
Username pulumi.StringPtrOutput `pulumi:"username"`
// When enabled, registry events are sent to the given Aqua webhook url
Webhooks IntegrationRegistryWebhookArrayOutput `pulumi:"webhooks"`
}
// NewIntegrationRegistry registers a new resource with the given unique name, arguments, and options.
func NewIntegrationRegistry(ctx *pulumi.Context,
name string, args *IntegrationRegistryArgs, opts ...pulumi.ResourceOption) (*IntegrationRegistry, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.Type == nil {
return nil, errors.New("invalid value for required argument 'Type'")
}
opts = internal.PkgResourceDefaultOpts(opts)
var resource IntegrationRegistry
err := ctx.RegisterResource("aquasec:index/integrationRegistry:IntegrationRegistry", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetIntegrationRegistry gets an existing IntegrationRegistry 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 GetIntegrationRegistry(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *IntegrationRegistryState, opts ...pulumi.ResourceOption) (*IntegrationRegistry, error) {
var resource IntegrationRegistry
err := ctx.ReadResource("aquasec:index/integrationRegistry:IntegrationRegistry", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering IntegrationRegistry resources.
type integrationRegistryState struct {
// Automatically clean up that don't match the pull criteria
AdvancedSettingsCleanup *bool `pulumi:"advancedSettingsCleanup"`
// List of image patterns to pull always
AlwaysPullPatterns []string `pulumi:"alwaysPullPatterns"`
// The username of the user who created or last modified the registry
Author *string `pulumi:"author"`
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
AutoCleanup *bool `pulumi:"autoCleanup"`
// Whether to automatically pull images from the registry on creation and daily
AutoPull *bool `pulumi:"autoPull"`
// The interval in days to start pulling new images from the registry, Defaults to 1
AutoPullInterval *int `pulumi:"autoPullInterval"`
// Maximum number of repositories to pull every day, defaults to 100
AutoPullMax *int `pulumi:"autoPullMax"`
// Whether to automatically pull and rescan images from the registry on creation and daily
AutoPullRescan *bool `pulumi:"autoPullRescan"`
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
AutoPullTime *string `pulumi:"autoPullTime"`
// The description of the registry
Description *string `pulumi:"description"`
// Additional condition for pulling and rescanning images, Defaults to 'none'
ImageCreationDateCondition *string `pulumi:"imageCreationDateCondition"`
// The last time the registry was modified in UNIX time
Lastupdate *int `pulumi:"lastupdate"`
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
Name *string `pulumi:"name"`
Options []IntegrationRegistryOption `pulumi:"options"`
// The password for registry authentication
Password *string `pulumi:"password"`
// List of possible prefixes to image names pulled from the registry
Prefixes []string `pulumi:"prefixes"`
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
PullImageAge *string `pulumi:"pullImageAge"`
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
PullImageCount *int `pulumi:"pullImageCount"`
// List of image tags patterns to pull
PullImageTagPatterns []string `pulumi:"pullImageTagPatterns"`
// List of image patterns to exclude
PullRepoPatternsExcludeds []string `pulumi:"pullRepoPatternsExcludeds"`
// Registry scan timeout in Minutes
RegistryScanTimeout *int `pulumi:"registryScanTimeout"`
// List of scanner names
ScannerNames []string `pulumi:"scannerNames"`
// The Scanner type
ScannerType *string `pulumi:"scannerType"`
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
Type *string `pulumi:"type"`
// The URL, address or region of the registry
Url *string `pulumi:"url"`
// The username for registry authentication.
Username *string `pulumi:"username"`
// When enabled, registry events are sent to the given Aqua webhook url
Webhooks []IntegrationRegistryWebhook `pulumi:"webhooks"`
}
type IntegrationRegistryState struct {
// Automatically clean up that don't match the pull criteria
AdvancedSettingsCleanup pulumi.BoolPtrInput
// List of image patterns to pull always
AlwaysPullPatterns pulumi.StringArrayInput
// The username of the user who created or last modified the registry
Author pulumi.StringPtrInput
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
AutoCleanup pulumi.BoolPtrInput
// Whether to automatically pull images from the registry on creation and daily
AutoPull pulumi.BoolPtrInput
// The interval in days to start pulling new images from the registry, Defaults to 1
AutoPullInterval pulumi.IntPtrInput
// Maximum number of repositories to pull every day, defaults to 100
AutoPullMax pulumi.IntPtrInput
// Whether to automatically pull and rescan images from the registry on creation and daily
AutoPullRescan pulumi.BoolPtrInput
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
AutoPullTime pulumi.StringPtrInput
// The description of the registry
Description pulumi.StringPtrInput
// Additional condition for pulling and rescanning images, Defaults to 'none'
ImageCreationDateCondition pulumi.StringPtrInput
// The last time the registry was modified in UNIX time
Lastupdate pulumi.IntPtrInput
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
Name pulumi.StringPtrInput
Options IntegrationRegistryOptionArrayInput
// The password for registry authentication
Password pulumi.StringPtrInput
// List of possible prefixes to image names pulled from the registry
Prefixes pulumi.StringArrayInput
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
PullImageAge pulumi.StringPtrInput
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
PullImageCount pulumi.IntPtrInput
// List of image tags patterns to pull
PullImageTagPatterns pulumi.StringArrayInput
// List of image patterns to exclude
PullRepoPatternsExcludeds pulumi.StringArrayInput
// Registry scan timeout in Minutes
RegistryScanTimeout pulumi.IntPtrInput
// List of scanner names
ScannerNames pulumi.StringArrayInput
// The Scanner type
ScannerType pulumi.StringPtrInput
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
Type pulumi.StringPtrInput
// The URL, address or region of the registry
Url pulumi.StringPtrInput
// The username for registry authentication.
Username pulumi.StringPtrInput
// When enabled, registry events are sent to the given Aqua webhook url
Webhooks IntegrationRegistryWebhookArrayInput
}
func (IntegrationRegistryState) ElementType() reflect.Type {
return reflect.TypeOf((*integrationRegistryState)(nil)).Elem()
}
type integrationRegistryArgs struct {
// Automatically clean up that don't match the pull criteria
AdvancedSettingsCleanup *bool `pulumi:"advancedSettingsCleanup"`
// List of image patterns to pull always
AlwaysPullPatterns []string `pulumi:"alwaysPullPatterns"`
// The username of the user who created or last modified the registry
Author *string `pulumi:"author"`
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
AutoCleanup *bool `pulumi:"autoCleanup"`
// Whether to automatically pull images from the registry on creation and daily
AutoPull *bool `pulumi:"autoPull"`
// The interval in days to start pulling new images from the registry, Defaults to 1
AutoPullInterval *int `pulumi:"autoPullInterval"`
// Maximum number of repositories to pull every day, defaults to 100
AutoPullMax *int `pulumi:"autoPullMax"`
// Whether to automatically pull and rescan images from the registry on creation and daily
AutoPullRescan *bool `pulumi:"autoPullRescan"`
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
AutoPullTime *string `pulumi:"autoPullTime"`
// The description of the registry
Description *string `pulumi:"description"`
// Additional condition for pulling and rescanning images, Defaults to 'none'
ImageCreationDateCondition *string `pulumi:"imageCreationDateCondition"`
// The last time the registry was modified in UNIX time
Lastupdate *int `pulumi:"lastupdate"`
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
Name *string `pulumi:"name"`
Options []IntegrationRegistryOption `pulumi:"options"`
// The password for registry authentication
Password *string `pulumi:"password"`
// List of possible prefixes to image names pulled from the registry
Prefixes []string `pulumi:"prefixes"`
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
PullImageAge *string `pulumi:"pullImageAge"`
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
PullImageCount *int `pulumi:"pullImageCount"`
// List of image tags patterns to pull
PullImageTagPatterns []string `pulumi:"pullImageTagPatterns"`
// List of image patterns to exclude
PullRepoPatternsExcludeds []string `pulumi:"pullRepoPatternsExcludeds"`
// Registry scan timeout in Minutes
RegistryScanTimeout *int `pulumi:"registryScanTimeout"`
// List of scanner names
ScannerNames []string `pulumi:"scannerNames"`
// The Scanner type
ScannerType *string `pulumi:"scannerType"`
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
Type string `pulumi:"type"`
// The URL, address or region of the registry
Url *string `pulumi:"url"`
// The username for registry authentication.
Username *string `pulumi:"username"`
// When enabled, registry events are sent to the given Aqua webhook url
Webhooks []IntegrationRegistryWebhook `pulumi:"webhooks"`
}
// The set of arguments for constructing a IntegrationRegistry resource.
type IntegrationRegistryArgs struct {
// Automatically clean up that don't match the pull criteria
AdvancedSettingsCleanup pulumi.BoolPtrInput
// List of image patterns to pull always
AlwaysPullPatterns pulumi.StringArrayInput
// The username of the user who created or last modified the registry
Author pulumi.StringPtrInput
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
AutoCleanup pulumi.BoolPtrInput
// Whether to automatically pull images from the registry on creation and daily
AutoPull pulumi.BoolPtrInput
// The interval in days to start pulling new images from the registry, Defaults to 1
AutoPullInterval pulumi.IntPtrInput
// Maximum number of repositories to pull every day, defaults to 100
AutoPullMax pulumi.IntPtrInput
// Whether to automatically pull and rescan images from the registry on creation and daily
AutoPullRescan pulumi.BoolPtrInput
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
AutoPullTime pulumi.StringPtrInput
// The description of the registry
Description pulumi.StringPtrInput
// Additional condition for pulling and rescanning images, Defaults to 'none'
ImageCreationDateCondition pulumi.StringPtrInput
// The last time the registry was modified in UNIX time
Lastupdate pulumi.IntPtrInput
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
Name pulumi.StringPtrInput
Options IntegrationRegistryOptionArrayInput
// The password for registry authentication
Password pulumi.StringPtrInput
// List of possible prefixes to image names pulled from the registry
Prefixes pulumi.StringArrayInput
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
PullImageAge pulumi.StringPtrInput
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
PullImageCount pulumi.IntPtrInput
// List of image tags patterns to pull
PullImageTagPatterns pulumi.StringArrayInput
// List of image patterns to exclude
PullRepoPatternsExcludeds pulumi.StringArrayInput
// Registry scan timeout in Minutes
RegistryScanTimeout pulumi.IntPtrInput
// List of scanner names
ScannerNames pulumi.StringArrayInput
// The Scanner type
ScannerType pulumi.StringPtrInput
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
Type pulumi.StringInput
// The URL, address or region of the registry
Url pulumi.StringPtrInput
// The username for registry authentication.
Username pulumi.StringPtrInput
// When enabled, registry events are sent to the given Aqua webhook url
Webhooks IntegrationRegistryWebhookArrayInput
}
func (IntegrationRegistryArgs) ElementType() reflect.Type {
return reflect.TypeOf((*integrationRegistryArgs)(nil)).Elem()
}
type IntegrationRegistryInput interface {
pulumi.Input
ToIntegrationRegistryOutput() IntegrationRegistryOutput
ToIntegrationRegistryOutputWithContext(ctx context.Context) IntegrationRegistryOutput
}
func (*IntegrationRegistry) ElementType() reflect.Type {
return reflect.TypeOf((**IntegrationRegistry)(nil)).Elem()
}
func (i *IntegrationRegistry) ToIntegrationRegistryOutput() IntegrationRegistryOutput {
return i.ToIntegrationRegistryOutputWithContext(context.Background())
}
func (i *IntegrationRegistry) ToIntegrationRegistryOutputWithContext(ctx context.Context) IntegrationRegistryOutput {
return pulumi.ToOutputWithContext(ctx, i).(IntegrationRegistryOutput)
}
// IntegrationRegistryArrayInput is an input type that accepts IntegrationRegistryArray and IntegrationRegistryArrayOutput values.
// You can construct a concrete instance of `IntegrationRegistryArrayInput` via:
//
// IntegrationRegistryArray{ IntegrationRegistryArgs{...} }
type IntegrationRegistryArrayInput interface {
pulumi.Input
ToIntegrationRegistryArrayOutput() IntegrationRegistryArrayOutput
ToIntegrationRegistryArrayOutputWithContext(context.Context) IntegrationRegistryArrayOutput
}
type IntegrationRegistryArray []IntegrationRegistryInput
func (IntegrationRegistryArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*IntegrationRegistry)(nil)).Elem()
}
func (i IntegrationRegistryArray) ToIntegrationRegistryArrayOutput() IntegrationRegistryArrayOutput {
return i.ToIntegrationRegistryArrayOutputWithContext(context.Background())
}
func (i IntegrationRegistryArray) ToIntegrationRegistryArrayOutputWithContext(ctx context.Context) IntegrationRegistryArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(IntegrationRegistryArrayOutput)
}
// IntegrationRegistryMapInput is an input type that accepts IntegrationRegistryMap and IntegrationRegistryMapOutput values.
// You can construct a concrete instance of `IntegrationRegistryMapInput` via:
//
// IntegrationRegistryMap{ "key": IntegrationRegistryArgs{...} }
type IntegrationRegistryMapInput interface {
pulumi.Input
ToIntegrationRegistryMapOutput() IntegrationRegistryMapOutput
ToIntegrationRegistryMapOutputWithContext(context.Context) IntegrationRegistryMapOutput
}
type IntegrationRegistryMap map[string]IntegrationRegistryInput
func (IntegrationRegistryMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*IntegrationRegistry)(nil)).Elem()
}
func (i IntegrationRegistryMap) ToIntegrationRegistryMapOutput() IntegrationRegistryMapOutput {
return i.ToIntegrationRegistryMapOutputWithContext(context.Background())
}
func (i IntegrationRegistryMap) ToIntegrationRegistryMapOutputWithContext(ctx context.Context) IntegrationRegistryMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(IntegrationRegistryMapOutput)
}
type IntegrationRegistryOutput struct{ *pulumi.OutputState }
func (IntegrationRegistryOutput) ElementType() reflect.Type {
return reflect.TypeOf((**IntegrationRegistry)(nil)).Elem()
}
func (o IntegrationRegistryOutput) ToIntegrationRegistryOutput() IntegrationRegistryOutput {
return o
}
func (o IntegrationRegistryOutput) ToIntegrationRegistryOutputWithContext(ctx context.Context) IntegrationRegistryOutput {
return o
}
// Automatically clean up that don't match the pull criteria
func (o IntegrationRegistryOutput) AdvancedSettingsCleanup() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.BoolPtrOutput { return v.AdvancedSettingsCleanup }).(pulumi.BoolPtrOutput)
}
// List of image patterns to pull always
func (o IntegrationRegistryOutput) AlwaysPullPatterns() pulumi.StringArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringArrayOutput { return v.AlwaysPullPatterns }).(pulumi.StringArrayOutput)
}
// The username of the user who created or last modified the registry
func (o IntegrationRegistryOutput) Author() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.Author }).(pulumi.StringOutput)
}
// Automatically clean up images and repositories which are no longer present in the registry from Aqua console
func (o IntegrationRegistryOutput) AutoCleanup() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.BoolPtrOutput { return v.AutoCleanup }).(pulumi.BoolPtrOutput)
}
// Whether to automatically pull images from the registry on creation and daily
func (o IntegrationRegistryOutput) AutoPull() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.BoolPtrOutput { return v.AutoPull }).(pulumi.BoolPtrOutput)
}
// The interval in days to start pulling new images from the registry, Defaults to 1
func (o IntegrationRegistryOutput) AutoPullInterval() pulumi.IntPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.IntPtrOutput { return v.AutoPullInterval }).(pulumi.IntPtrOutput)
}
// Maximum number of repositories to pull every day, defaults to 100
func (o IntegrationRegistryOutput) AutoPullMax() pulumi.IntPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.IntPtrOutput { return v.AutoPullMax }).(pulumi.IntPtrOutput)
}
// Whether to automatically pull and rescan images from the registry on creation and daily
func (o IntegrationRegistryOutput) AutoPullRescan() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.BoolPtrOutput { return v.AutoPullRescan }).(pulumi.BoolPtrOutput)
}
// The time of day to start pulling new images from the registry, in the format HH:MM (24-hour clock), defaults to 03:00
func (o IntegrationRegistryOutput) AutoPullTime() pulumi.StringPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringPtrOutput { return v.AutoPullTime }).(pulumi.StringPtrOutput)
}
// The description of the registry
func (o IntegrationRegistryOutput) Description() pulumi.StringPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringPtrOutput { return v.Description }).(pulumi.StringPtrOutput)
}
// Additional condition for pulling and rescanning images, Defaults to 'none'
func (o IntegrationRegistryOutput) ImageCreationDateCondition() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.ImageCreationDateCondition }).(pulumi.StringOutput)
}
// The last time the registry was modified in UNIX time
func (o IntegrationRegistryOutput) Lastupdate() pulumi.IntOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.IntOutput { return v.Lastupdate }).(pulumi.IntOutput)
}
// The name of the registry; string, required - this will be treated as the registry's ID, so choose a simple alphanumerical name without special signs and spaces
func (o IntegrationRegistryOutput) Name() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)
}
func (o IntegrationRegistryOutput) Options() IntegrationRegistryOptionArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) IntegrationRegistryOptionArrayOutput { return v.Options }).(IntegrationRegistryOptionArrayOutput)
}
// The password for registry authentication
func (o IntegrationRegistryOutput) Password() pulumi.StringPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringPtrOutput { return v.Password }).(pulumi.StringPtrOutput)
}
// List of possible prefixes to image names pulled from the registry
func (o IntegrationRegistryOutput) Prefixes() pulumi.StringArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringArrayOutput { return v.Prefixes }).(pulumi.StringArrayOutput)
}
// When auto pull image enabled, sets maximum age of auto pulled images (for example for 5 Days the value should be: 5D), Requires `imageCreationDateCondition = "imageAge"`
func (o IntegrationRegistryOutput) PullImageAge() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.PullImageAge }).(pulumi.StringOutput)
}
// When auto pull image enabled, sets maximum age of auto pulled images tags from each repository (based on image creation date) Requires `imageCreationDateCondition = "imageCount"`
func (o IntegrationRegistryOutput) PullImageCount() pulumi.IntOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.IntOutput { return v.PullImageCount }).(pulumi.IntOutput)
}
// List of image tags patterns to pull
func (o IntegrationRegistryOutput) PullImageTagPatterns() pulumi.StringArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringArrayOutput { return v.PullImageTagPatterns }).(pulumi.StringArrayOutput)
}
// List of image patterns to exclude
func (o IntegrationRegistryOutput) PullRepoPatternsExcludeds() pulumi.StringArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringArrayOutput { return v.PullRepoPatternsExcludeds }).(pulumi.StringArrayOutput)
}
// Registry scan timeout in Minutes
func (o IntegrationRegistryOutput) RegistryScanTimeout() pulumi.IntPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.IntPtrOutput { return v.RegistryScanTimeout }).(pulumi.IntPtrOutput)
}
// List of scanner names
func (o IntegrationRegistryOutput) ScannerNames() pulumi.StringArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringArrayOutput { return v.ScannerNames }).(pulumi.StringArrayOutput)
}
// The Scanner type
func (o IntegrationRegistryOutput) ScannerType() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.ScannerType }).(pulumi.StringOutput)
}
// Registry type (HUB / V1 / V2 / ACR / GAR / ENGINE / AWS / GCR).
func (o IntegrationRegistryOutput) Type() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.Type }).(pulumi.StringOutput)
}
// The URL, address or region of the registry
func (o IntegrationRegistryOutput) Url() pulumi.StringOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringOutput { return v.Url }).(pulumi.StringOutput)
}
// The username for registry authentication.
func (o IntegrationRegistryOutput) Username() pulumi.StringPtrOutput {
return o.ApplyT(func(v *IntegrationRegistry) pulumi.StringPtrOutput { return v.Username }).(pulumi.StringPtrOutput)
}
// When enabled, registry events are sent to the given Aqua webhook url
func (o IntegrationRegistryOutput) Webhooks() IntegrationRegistryWebhookArrayOutput {
return o.ApplyT(func(v *IntegrationRegistry) IntegrationRegistryWebhookArrayOutput { return v.Webhooks }).(IntegrationRegistryWebhookArrayOutput)
}
type IntegrationRegistryArrayOutput struct{ *pulumi.OutputState }
func (IntegrationRegistryArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*IntegrationRegistry)(nil)).Elem()
}
func (o IntegrationRegistryArrayOutput) ToIntegrationRegistryArrayOutput() IntegrationRegistryArrayOutput {
return o
}
func (o IntegrationRegistryArrayOutput) ToIntegrationRegistryArrayOutputWithContext(ctx context.Context) IntegrationRegistryArrayOutput {
return o
}
func (o IntegrationRegistryArrayOutput) Index(i pulumi.IntInput) IntegrationRegistryOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *IntegrationRegistry {
return vs[0].([]*IntegrationRegistry)[vs[1].(int)]
}).(IntegrationRegistryOutput)
}
type IntegrationRegistryMapOutput struct{ *pulumi.OutputState }
func (IntegrationRegistryMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*IntegrationRegistry)(nil)).Elem()
}
func (o IntegrationRegistryMapOutput) ToIntegrationRegistryMapOutput() IntegrationRegistryMapOutput {
return o
}
func (o IntegrationRegistryMapOutput) ToIntegrationRegistryMapOutputWithContext(ctx context.Context) IntegrationRegistryMapOutput {
return o
}
func (o IntegrationRegistryMapOutput) MapIndex(k pulumi.StringInput) IntegrationRegistryOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *IntegrationRegistry {
return vs[0].(map[string]*IntegrationRegistry)[vs[1].(string)]
}).(IntegrationRegistryOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*IntegrationRegistryInput)(nil)).Elem(), &IntegrationRegistry{})
pulumi.RegisterInputType(reflect.TypeOf((*IntegrationRegistryArrayInput)(nil)).Elem(), IntegrationRegistryArray{})
pulumi.RegisterInputType(reflect.TypeOf((*IntegrationRegistryMapInput)(nil)).Elem(), IntegrationRegistryMap{})
pulumi.RegisterOutputType(IntegrationRegistryOutput{})
pulumi.RegisterOutputType(IntegrationRegistryArrayOutput{})
pulumi.RegisterOutputType(IntegrationRegistryMapOutput{})
}