/
cluster.go
959 lines (869 loc) · 60.5 KB
/
cluster.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
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
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
// 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 redshift
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Provides a Redshift Cluster Resource.
//
// > **NOTE:** A Redshift cluster's default IAM role can be managed both by this resource's `defaultIamRoleArn` argument and the `redshift.ClusterIamRoles` resource's `defaultIamRoleArn` argument. Do not configure different values for both arguments. Doing so will cause a conflict of default IAM roles.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-aws/sdk/v5/go/aws/redshift"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := redshift.NewCluster(ctx, "example", &redshift.ClusterArgs{
// ClusterIdentifier: pulumi.String("tf-redshift-cluster"),
// ClusterType: pulumi.String("single-node"),
// DatabaseName: pulumi.String("mydb"),
// MasterPassword: pulumi.String("Mustbe8characters"),
// MasterUsername: pulumi.String("exampleuser"),
// NodeType: pulumi.String("dc1.large"),
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// Redshift Clusters can be imported using the `cluster_identifier`, e.g.,
//
// ```sh
//
// $ pulumi import aws:redshift/cluster:Cluster myprodcluster tf-redshift-cluster-12345
//
// ```
type Cluster struct {
pulumi.CustomResourceState
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
AllowVersionUpgrade pulumi.BoolPtrOutput `pulumi:"allowVersionUpgrade"`
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
ApplyImmediately pulumi.BoolPtrOutput `pulumi:"applyImmediately"`
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
AquaConfigurationStatus pulumi.StringOutput `pulumi:"aquaConfigurationStatus"`
// Amazon Resource Name (ARN) of cluster
Arn pulumi.StringOutput `pulumi:"arn"`
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
AutomatedSnapshotRetentionPeriod pulumi.IntPtrOutput `pulumi:"automatedSnapshotRetentionPeriod"`
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
AvailabilityZone pulumi.StringOutput `pulumi:"availabilityZone"`
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
AvailabilityZoneRelocationEnabled pulumi.BoolPtrOutput `pulumi:"availabilityZoneRelocationEnabled"`
// The Cluster Identifier. Must be a lower case string.
ClusterIdentifier pulumi.StringOutput `pulumi:"clusterIdentifier"`
// The nodes in the cluster. Cluster node blocks are documented below
ClusterNodes ClusterClusterNodeArrayOutput `pulumi:"clusterNodes"`
// The name of the parameter group to be associated with this cluster.
ClusterParameterGroupName pulumi.StringOutput `pulumi:"clusterParameterGroupName"`
// The public key for the cluster
ClusterPublicKey pulumi.StringOutput `pulumi:"clusterPublicKey"`
// The specific revision number of the database in the cluster
ClusterRevisionNumber pulumi.StringOutput `pulumi:"clusterRevisionNumber"`
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
ClusterSecurityGroups pulumi.StringArrayOutput `pulumi:"clusterSecurityGroups"`
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
ClusterSubnetGroupName pulumi.StringOutput `pulumi:"clusterSubnetGroupName"`
// The cluster type to use. Either `single-node` or `multi-node`.
ClusterType pulumi.StringOutput `pulumi:"clusterType"`
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
ClusterVersion pulumi.StringPtrOutput `pulumi:"clusterVersion"`
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
DatabaseName pulumi.StringOutput `pulumi:"databaseName"`
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
DefaultIamRoleArn pulumi.StringOutput `pulumi:"defaultIamRoleArn"`
// The DNS name of the cluster
DnsName pulumi.StringOutput `pulumi:"dnsName"`
// The Elastic IP (EIP) address for the cluster.
ElasticIp pulumi.StringPtrOutput `pulumi:"elasticIp"`
// If true , the data in the cluster is encrypted at rest.
Encrypted pulumi.BoolPtrOutput `pulumi:"encrypted"`
// The connection endpoint
Endpoint pulumi.StringOutput `pulumi:"endpoint"`
// If true , enhanced VPC routing is enabled.
EnhancedVpcRouting pulumi.BoolOutput `pulumi:"enhancedVpcRouting"`
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
FinalSnapshotIdentifier pulumi.StringPtrOutput `pulumi:"finalSnapshotIdentifier"`
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
IamRoles pulumi.StringArrayOutput `pulumi:"iamRoles"`
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
KmsKeyId pulumi.StringOutput `pulumi:"kmsKeyId"`
// Logging, documented below.
Logging ClusterLoggingPtrOutput `pulumi:"logging"`
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
MaintenanceTrackName pulumi.StringPtrOutput `pulumi:"maintenanceTrackName"`
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
ManualSnapshotRetentionPeriod pulumi.IntPtrOutput `pulumi:"manualSnapshotRetentionPeriod"`
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
MasterPassword pulumi.StringPtrOutput `pulumi:"masterPassword"`
// Username for the master DB user.
MasterUsername pulumi.StringPtrOutput `pulumi:"masterUsername"`
// The node type to be provisioned for the cluster.
NodeType pulumi.StringOutput `pulumi:"nodeType"`
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
NumberOfNodes pulumi.IntPtrOutput `pulumi:"numberOfNodes"`
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
OwnerAccount pulumi.StringPtrOutput `pulumi:"ownerAccount"`
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
Port pulumi.IntPtrOutput `pulumi:"port"`
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
PreferredMaintenanceWindow pulumi.StringOutput `pulumi:"preferredMaintenanceWindow"`
// If true, the cluster can be accessed from a public network. Default is `true`.
PubliclyAccessible pulumi.BoolPtrOutput `pulumi:"publiclyAccessible"`
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
SkipFinalSnapshot pulumi.BoolPtrOutput `pulumi:"skipFinalSnapshot"`
// The name of the cluster the source snapshot was created from.
SnapshotClusterIdentifier pulumi.StringPtrOutput `pulumi:"snapshotClusterIdentifier"`
// Configuration of automatic copy of snapshots from one region to another. Documented below.
SnapshotCopy ClusterSnapshotCopyPtrOutput `pulumi:"snapshotCopy"`
// The name of the snapshot from which to create the new cluster.
SnapshotIdentifier pulumi.StringPtrOutput `pulumi:"snapshotIdentifier"`
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapOutput `pulumi:"tags"`
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"`
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
VpcSecurityGroupIds pulumi.StringArrayOutput `pulumi:"vpcSecurityGroupIds"`
}
// NewCluster registers a new resource with the given unique name, arguments, and options.
func NewCluster(ctx *pulumi.Context,
name string, args *ClusterArgs, opts ...pulumi.ResourceOption) (*Cluster, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.ClusterIdentifier == nil {
return nil, errors.New("invalid value for required argument 'ClusterIdentifier'")
}
if args.NodeType == nil {
return nil, errors.New("invalid value for required argument 'NodeType'")
}
if args.MasterPassword != nil {
args.MasterPassword = pulumi.ToSecret(args.MasterPassword).(pulumi.StringPtrInput)
}
secrets := pulumi.AdditionalSecretOutputs([]string{
"masterPassword",
})
opts = append(opts, secrets)
var resource Cluster
err := ctx.RegisterResource("aws:redshift/cluster:Cluster", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetCluster gets an existing Cluster 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 GetCluster(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *ClusterState, opts ...pulumi.ResourceOption) (*Cluster, error) {
var resource Cluster
err := ctx.ReadResource("aws:redshift/cluster:Cluster", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering Cluster resources.
type clusterState struct {
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
AllowVersionUpgrade *bool `pulumi:"allowVersionUpgrade"`
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
ApplyImmediately *bool `pulumi:"applyImmediately"`
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
AquaConfigurationStatus *string `pulumi:"aquaConfigurationStatus"`
// Amazon Resource Name (ARN) of cluster
Arn *string `pulumi:"arn"`
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
AutomatedSnapshotRetentionPeriod *int `pulumi:"automatedSnapshotRetentionPeriod"`
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
AvailabilityZone *string `pulumi:"availabilityZone"`
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
AvailabilityZoneRelocationEnabled *bool `pulumi:"availabilityZoneRelocationEnabled"`
// The Cluster Identifier. Must be a lower case string.
ClusterIdentifier *string `pulumi:"clusterIdentifier"`
// The nodes in the cluster. Cluster node blocks are documented below
ClusterNodes []ClusterClusterNode `pulumi:"clusterNodes"`
// The name of the parameter group to be associated with this cluster.
ClusterParameterGroupName *string `pulumi:"clusterParameterGroupName"`
// The public key for the cluster
ClusterPublicKey *string `pulumi:"clusterPublicKey"`
// The specific revision number of the database in the cluster
ClusterRevisionNumber *string `pulumi:"clusterRevisionNumber"`
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
ClusterSecurityGroups []string `pulumi:"clusterSecurityGroups"`
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
ClusterSubnetGroupName *string `pulumi:"clusterSubnetGroupName"`
// The cluster type to use. Either `single-node` or `multi-node`.
ClusterType *string `pulumi:"clusterType"`
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
ClusterVersion *string `pulumi:"clusterVersion"`
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
DatabaseName *string `pulumi:"databaseName"`
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
DefaultIamRoleArn *string `pulumi:"defaultIamRoleArn"`
// The DNS name of the cluster
DnsName *string `pulumi:"dnsName"`
// The Elastic IP (EIP) address for the cluster.
ElasticIp *string `pulumi:"elasticIp"`
// If true , the data in the cluster is encrypted at rest.
Encrypted *bool `pulumi:"encrypted"`
// The connection endpoint
Endpoint *string `pulumi:"endpoint"`
// If true , enhanced VPC routing is enabled.
EnhancedVpcRouting *bool `pulumi:"enhancedVpcRouting"`
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
FinalSnapshotIdentifier *string `pulumi:"finalSnapshotIdentifier"`
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
IamRoles []string `pulumi:"iamRoles"`
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
KmsKeyId *string `pulumi:"kmsKeyId"`
// Logging, documented below.
Logging *ClusterLogging `pulumi:"logging"`
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
MaintenanceTrackName *string `pulumi:"maintenanceTrackName"`
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
ManualSnapshotRetentionPeriod *int `pulumi:"manualSnapshotRetentionPeriod"`
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
MasterPassword *string `pulumi:"masterPassword"`
// Username for the master DB user.
MasterUsername *string `pulumi:"masterUsername"`
// The node type to be provisioned for the cluster.
NodeType *string `pulumi:"nodeType"`
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
NumberOfNodes *int `pulumi:"numberOfNodes"`
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
OwnerAccount *string `pulumi:"ownerAccount"`
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
Port *int `pulumi:"port"`
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
PreferredMaintenanceWindow *string `pulumi:"preferredMaintenanceWindow"`
// If true, the cluster can be accessed from a public network. Default is `true`.
PubliclyAccessible *bool `pulumi:"publiclyAccessible"`
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
SkipFinalSnapshot *bool `pulumi:"skipFinalSnapshot"`
// The name of the cluster the source snapshot was created from.
SnapshotClusterIdentifier *string `pulumi:"snapshotClusterIdentifier"`
// Configuration of automatic copy of snapshots from one region to another. Documented below.
SnapshotCopy *ClusterSnapshotCopy `pulumi:"snapshotCopy"`
// The name of the snapshot from which to create the new cluster.
SnapshotIdentifier *string `pulumi:"snapshotIdentifier"`
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll map[string]string `pulumi:"tagsAll"`
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
VpcSecurityGroupIds []string `pulumi:"vpcSecurityGroupIds"`
}
type ClusterState struct {
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
AllowVersionUpgrade pulumi.BoolPtrInput
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
ApplyImmediately pulumi.BoolPtrInput
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
AquaConfigurationStatus pulumi.StringPtrInput
// Amazon Resource Name (ARN) of cluster
Arn pulumi.StringPtrInput
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
AutomatedSnapshotRetentionPeriod pulumi.IntPtrInput
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
AvailabilityZone pulumi.StringPtrInput
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
AvailabilityZoneRelocationEnabled pulumi.BoolPtrInput
// The Cluster Identifier. Must be a lower case string.
ClusterIdentifier pulumi.StringPtrInput
// The nodes in the cluster. Cluster node blocks are documented below
ClusterNodes ClusterClusterNodeArrayInput
// The name of the parameter group to be associated with this cluster.
ClusterParameterGroupName pulumi.StringPtrInput
// The public key for the cluster
ClusterPublicKey pulumi.StringPtrInput
// The specific revision number of the database in the cluster
ClusterRevisionNumber pulumi.StringPtrInput
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
ClusterSecurityGroups pulumi.StringArrayInput
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
ClusterSubnetGroupName pulumi.StringPtrInput
// The cluster type to use. Either `single-node` or `multi-node`.
ClusterType pulumi.StringPtrInput
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
ClusterVersion pulumi.StringPtrInput
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
DatabaseName pulumi.StringPtrInput
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
DefaultIamRoleArn pulumi.StringPtrInput
// The DNS name of the cluster
DnsName pulumi.StringPtrInput
// The Elastic IP (EIP) address for the cluster.
ElasticIp pulumi.StringPtrInput
// If true , the data in the cluster is encrypted at rest.
Encrypted pulumi.BoolPtrInput
// The connection endpoint
Endpoint pulumi.StringPtrInput
// If true , enhanced VPC routing is enabled.
EnhancedVpcRouting pulumi.BoolPtrInput
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
FinalSnapshotIdentifier pulumi.StringPtrInput
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
IamRoles pulumi.StringArrayInput
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
KmsKeyId pulumi.StringPtrInput
// Logging, documented below.
Logging ClusterLoggingPtrInput
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
MaintenanceTrackName pulumi.StringPtrInput
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
ManualSnapshotRetentionPeriod pulumi.IntPtrInput
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
MasterPassword pulumi.StringPtrInput
// Username for the master DB user.
MasterUsername pulumi.StringPtrInput
// The node type to be provisioned for the cluster.
NodeType pulumi.StringPtrInput
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
NumberOfNodes pulumi.IntPtrInput
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
OwnerAccount pulumi.StringPtrInput
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
Port pulumi.IntPtrInput
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
PreferredMaintenanceWindow pulumi.StringPtrInput
// If true, the cluster can be accessed from a public network. Default is `true`.
PubliclyAccessible pulumi.BoolPtrInput
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
SkipFinalSnapshot pulumi.BoolPtrInput
// The name of the cluster the source snapshot was created from.
SnapshotClusterIdentifier pulumi.StringPtrInput
// Configuration of automatic copy of snapshots from one region to another. Documented below.
SnapshotCopy ClusterSnapshotCopyPtrInput
// The name of the snapshot from which to create the new cluster.
SnapshotIdentifier pulumi.StringPtrInput
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll pulumi.StringMapInput
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
VpcSecurityGroupIds pulumi.StringArrayInput
}
func (ClusterState) ElementType() reflect.Type {
return reflect.TypeOf((*clusterState)(nil)).Elem()
}
type clusterArgs struct {
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
AllowVersionUpgrade *bool `pulumi:"allowVersionUpgrade"`
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
ApplyImmediately *bool `pulumi:"applyImmediately"`
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
AquaConfigurationStatus *string `pulumi:"aquaConfigurationStatus"`
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
AutomatedSnapshotRetentionPeriod *int `pulumi:"automatedSnapshotRetentionPeriod"`
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
AvailabilityZone *string `pulumi:"availabilityZone"`
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
AvailabilityZoneRelocationEnabled *bool `pulumi:"availabilityZoneRelocationEnabled"`
// The Cluster Identifier. Must be a lower case string.
ClusterIdentifier string `pulumi:"clusterIdentifier"`
// The name of the parameter group to be associated with this cluster.
ClusterParameterGroupName *string `pulumi:"clusterParameterGroupName"`
// The public key for the cluster
ClusterPublicKey *string `pulumi:"clusterPublicKey"`
// The specific revision number of the database in the cluster
ClusterRevisionNumber *string `pulumi:"clusterRevisionNumber"`
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
ClusterSecurityGroups []string `pulumi:"clusterSecurityGroups"`
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
ClusterSubnetGroupName *string `pulumi:"clusterSubnetGroupName"`
// The cluster type to use. Either `single-node` or `multi-node`.
ClusterType *string `pulumi:"clusterType"`
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
ClusterVersion *string `pulumi:"clusterVersion"`
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
DatabaseName *string `pulumi:"databaseName"`
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
DefaultIamRoleArn *string `pulumi:"defaultIamRoleArn"`
// The Elastic IP (EIP) address for the cluster.
ElasticIp *string `pulumi:"elasticIp"`
// If true , the data in the cluster is encrypted at rest.
Encrypted *bool `pulumi:"encrypted"`
// The connection endpoint
Endpoint *string `pulumi:"endpoint"`
// If true , enhanced VPC routing is enabled.
EnhancedVpcRouting *bool `pulumi:"enhancedVpcRouting"`
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
FinalSnapshotIdentifier *string `pulumi:"finalSnapshotIdentifier"`
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
IamRoles []string `pulumi:"iamRoles"`
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
KmsKeyId *string `pulumi:"kmsKeyId"`
// Logging, documented below.
Logging *ClusterLogging `pulumi:"logging"`
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
MaintenanceTrackName *string `pulumi:"maintenanceTrackName"`
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
ManualSnapshotRetentionPeriod *int `pulumi:"manualSnapshotRetentionPeriod"`
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
MasterPassword *string `pulumi:"masterPassword"`
// Username for the master DB user.
MasterUsername *string `pulumi:"masterUsername"`
// The node type to be provisioned for the cluster.
NodeType string `pulumi:"nodeType"`
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
NumberOfNodes *int `pulumi:"numberOfNodes"`
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
OwnerAccount *string `pulumi:"ownerAccount"`
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
Port *int `pulumi:"port"`
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
PreferredMaintenanceWindow *string `pulumi:"preferredMaintenanceWindow"`
// If true, the cluster can be accessed from a public network. Default is `true`.
PubliclyAccessible *bool `pulumi:"publiclyAccessible"`
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
SkipFinalSnapshot *bool `pulumi:"skipFinalSnapshot"`
// The name of the cluster the source snapshot was created from.
SnapshotClusterIdentifier *string `pulumi:"snapshotClusterIdentifier"`
// Configuration of automatic copy of snapshots from one region to another. Documented below.
SnapshotCopy *ClusterSnapshotCopy `pulumi:"snapshotCopy"`
// The name of the snapshot from which to create the new cluster.
SnapshotIdentifier *string `pulumi:"snapshotIdentifier"`
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
VpcSecurityGroupIds []string `pulumi:"vpcSecurityGroupIds"`
}
// The set of arguments for constructing a Cluster resource.
type ClusterArgs struct {
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
AllowVersionUpgrade pulumi.BoolPtrInput
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
ApplyImmediately pulumi.BoolPtrInput
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
AquaConfigurationStatus pulumi.StringPtrInput
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
AutomatedSnapshotRetentionPeriod pulumi.IntPtrInput
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
AvailabilityZone pulumi.StringPtrInput
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
AvailabilityZoneRelocationEnabled pulumi.BoolPtrInput
// The Cluster Identifier. Must be a lower case string.
ClusterIdentifier pulumi.StringInput
// The name of the parameter group to be associated with this cluster.
ClusterParameterGroupName pulumi.StringPtrInput
// The public key for the cluster
ClusterPublicKey pulumi.StringPtrInput
// The specific revision number of the database in the cluster
ClusterRevisionNumber pulumi.StringPtrInput
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
ClusterSecurityGroups pulumi.StringArrayInput
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
ClusterSubnetGroupName pulumi.StringPtrInput
// The cluster type to use. Either `single-node` or `multi-node`.
ClusterType pulumi.StringPtrInput
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
ClusterVersion pulumi.StringPtrInput
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
DatabaseName pulumi.StringPtrInput
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
DefaultIamRoleArn pulumi.StringPtrInput
// The Elastic IP (EIP) address for the cluster.
ElasticIp pulumi.StringPtrInput
// If true , the data in the cluster is encrypted at rest.
Encrypted pulumi.BoolPtrInput
// The connection endpoint
Endpoint pulumi.StringPtrInput
// If true , enhanced VPC routing is enabled.
EnhancedVpcRouting pulumi.BoolPtrInput
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
FinalSnapshotIdentifier pulumi.StringPtrInput
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
IamRoles pulumi.StringArrayInput
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
KmsKeyId pulumi.StringPtrInput
// Logging, documented below.
Logging ClusterLoggingPtrInput
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
MaintenanceTrackName pulumi.StringPtrInput
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
ManualSnapshotRetentionPeriod pulumi.IntPtrInput
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
MasterPassword pulumi.StringPtrInput
// Username for the master DB user.
MasterUsername pulumi.StringPtrInput
// The node type to be provisioned for the cluster.
NodeType pulumi.StringInput
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
NumberOfNodes pulumi.IntPtrInput
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
OwnerAccount pulumi.StringPtrInput
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
Port pulumi.IntPtrInput
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
PreferredMaintenanceWindow pulumi.StringPtrInput
// If true, the cluster can be accessed from a public network. Default is `true`.
PubliclyAccessible pulumi.BoolPtrInput
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
SkipFinalSnapshot pulumi.BoolPtrInput
// The name of the cluster the source snapshot was created from.
SnapshotClusterIdentifier pulumi.StringPtrInput
// Configuration of automatic copy of snapshots from one region to another. Documented below.
SnapshotCopy ClusterSnapshotCopyPtrInput
// The name of the snapshot from which to create the new cluster.
SnapshotIdentifier pulumi.StringPtrInput
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
VpcSecurityGroupIds pulumi.StringArrayInput
}
func (ClusterArgs) ElementType() reflect.Type {
return reflect.TypeOf((*clusterArgs)(nil)).Elem()
}
type ClusterInput interface {
pulumi.Input
ToClusterOutput() ClusterOutput
ToClusterOutputWithContext(ctx context.Context) ClusterOutput
}
func (*Cluster) ElementType() reflect.Type {
return reflect.TypeOf((**Cluster)(nil)).Elem()
}
func (i *Cluster) ToClusterOutput() ClusterOutput {
return i.ToClusterOutputWithContext(context.Background())
}
func (i *Cluster) ToClusterOutputWithContext(ctx context.Context) ClusterOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterOutput)
}
// ClusterArrayInput is an input type that accepts ClusterArray and ClusterArrayOutput values.
// You can construct a concrete instance of `ClusterArrayInput` via:
//
// ClusterArray{ ClusterArgs{...} }
type ClusterArrayInput interface {
pulumi.Input
ToClusterArrayOutput() ClusterArrayOutput
ToClusterArrayOutputWithContext(context.Context) ClusterArrayOutput
}
type ClusterArray []ClusterInput
func (ClusterArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Cluster)(nil)).Elem()
}
func (i ClusterArray) ToClusterArrayOutput() ClusterArrayOutput {
return i.ToClusterArrayOutputWithContext(context.Background())
}
func (i ClusterArray) ToClusterArrayOutputWithContext(ctx context.Context) ClusterArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterArrayOutput)
}
// ClusterMapInput is an input type that accepts ClusterMap and ClusterMapOutput values.
// You can construct a concrete instance of `ClusterMapInput` via:
//
// ClusterMap{ "key": ClusterArgs{...} }
type ClusterMapInput interface {
pulumi.Input
ToClusterMapOutput() ClusterMapOutput
ToClusterMapOutputWithContext(context.Context) ClusterMapOutput
}
type ClusterMap map[string]ClusterInput
func (ClusterMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Cluster)(nil)).Elem()
}
func (i ClusterMap) ToClusterMapOutput() ClusterMapOutput {
return i.ToClusterMapOutputWithContext(context.Background())
}
func (i ClusterMap) ToClusterMapOutputWithContext(ctx context.Context) ClusterMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterMapOutput)
}
type ClusterOutput struct{ *pulumi.OutputState }
func (ClusterOutput) ElementType() reflect.Type {
return reflect.TypeOf((**Cluster)(nil)).Elem()
}
func (o ClusterOutput) ToClusterOutput() ClusterOutput {
return o
}
func (o ClusterOutput) ToClusterOutputWithContext(ctx context.Context) ClusterOutput {
return o
}
// If true , major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default is `true`.
func (o ClusterOutput) AllowVersionUpgrade() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.AllowVersionUpgrade }).(pulumi.BoolPtrOutput)
}
// Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is `false`.
func (o ClusterOutput) ApplyImmediately() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.ApplyImmediately }).(pulumi.BoolPtrOutput)
}
// The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values are `enabled`, `disabled`, and `auto`. Requires Cluster reboot.
func (o ClusterOutput) AquaConfigurationStatus() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.AquaConfigurationStatus }).(pulumi.StringOutput)
}
// Amazon Resource Name (ARN) of cluster
func (o ClusterOutput) Arn() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput)
}
// The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with create-cluster-snapshot. Default is 1.
func (o ClusterOutput) AutomatedSnapshotRetentionPeriod() pulumi.IntPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.IntPtrOutput { return v.AutomatedSnapshotRetentionPeriod }).(pulumi.IntPtrOutput)
}
// The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. For example, if you have several EC2 instances running in a specific Availability Zone, then you might want the cluster to be provisioned in the same zone in order to decrease network latency. Can only be changed if `availabilityZoneRelocationEnabled` is `true`.
func (o ClusterOutput) AvailabilityZone() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.AvailabilityZone }).(pulumi.StringOutput)
}
// If true, the cluster can be relocated to another availabity zone, either automatically by AWS or when requested. Default is `false`. Available for use on clusters from the RA3 instance family.
func (o ClusterOutput) AvailabilityZoneRelocationEnabled() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.AvailabilityZoneRelocationEnabled }).(pulumi.BoolPtrOutput)
}
// The Cluster Identifier. Must be a lower case string.
func (o ClusterOutput) ClusterIdentifier() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterIdentifier }).(pulumi.StringOutput)
}
// The nodes in the cluster. Cluster node blocks are documented below
func (o ClusterOutput) ClusterNodes() ClusterClusterNodeArrayOutput {
return o.ApplyT(func(v *Cluster) ClusterClusterNodeArrayOutput { return v.ClusterNodes }).(ClusterClusterNodeArrayOutput)
}
// The name of the parameter group to be associated with this cluster.
func (o ClusterOutput) ClusterParameterGroupName() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterParameterGroupName }).(pulumi.StringOutput)
}
// The public key for the cluster
func (o ClusterOutput) ClusterPublicKey() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterPublicKey }).(pulumi.StringOutput)
}
// The specific revision number of the database in the cluster
func (o ClusterOutput) ClusterRevisionNumber() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterRevisionNumber }).(pulumi.StringOutput)
}
// A list of security groups to be associated with this cluster.
//
// Deprecated: With the retirement of EC2-Classic the cluster_security_groups attribute has been deprecated and will be removed in a future version.
func (o ClusterOutput) ClusterSecurityGroups() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringArrayOutput { return v.ClusterSecurityGroups }).(pulumi.StringArrayOutput)
}
// The name of a cluster subnet group to be associated with this cluster. If this parameter is not provided the resulting cluster will be deployed outside virtual private cloud (VPC).
func (o ClusterOutput) ClusterSubnetGroupName() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterSubnetGroupName }).(pulumi.StringOutput)
}
// The cluster type to use. Either `single-node` or `multi-node`.
func (o ClusterOutput) ClusterType() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClusterType }).(pulumi.StringOutput)
}
// The version of the Amazon Redshift engine software that you want to deploy on the cluster.
// The version selected runs on all the nodes in the cluster.
func (o ClusterOutput) ClusterVersion() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.ClusterVersion }).(pulumi.StringPtrOutput)
}
// The name of the first database to be created when the cluster is created.
// If you do not provide a name, Amazon Redshift will create a default database called `dev`.
func (o ClusterOutput) DatabaseName() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.DatabaseName }).(pulumi.StringOutput)
}
// The Amazon Resource Name (ARN) for the IAM role that was set as default for the cluster when the cluster was created.
func (o ClusterOutput) DefaultIamRoleArn() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.DefaultIamRoleArn }).(pulumi.StringOutput)
}
// The DNS name of the cluster
func (o ClusterOutput) DnsName() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.DnsName }).(pulumi.StringOutput)
}
// The Elastic IP (EIP) address for the cluster.
func (o ClusterOutput) ElasticIp() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.ElasticIp }).(pulumi.StringPtrOutput)
}
// If true , the data in the cluster is encrypted at rest.
func (o ClusterOutput) Encrypted() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.Encrypted }).(pulumi.BoolPtrOutput)
}
// The connection endpoint
func (o ClusterOutput) Endpoint() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.Endpoint }).(pulumi.StringOutput)
}
// If true , enhanced VPC routing is enabled.
func (o ClusterOutput) EnhancedVpcRouting() pulumi.BoolOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolOutput { return v.EnhancedVpcRouting }).(pulumi.BoolOutput)
}
// The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, `skipFinalSnapshot` must be false.
func (o ClusterOutput) FinalSnapshotIdentifier() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.FinalSnapshotIdentifier }).(pulumi.StringPtrOutput)
}
// A list of IAM Role ARNs to associate with the cluster. A Maximum of 10 can be associated to the cluster at any time.
func (o ClusterOutput) IamRoles() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringArrayOutput { return v.IamRoles }).(pulumi.StringArrayOutput)
}
// The ARN for the KMS encryption key. When specifying `kmsKeyId`, `encrypted` needs to be set to true.
func (o ClusterOutput) KmsKeyId() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.KmsKeyId }).(pulumi.StringOutput)
}
// Logging, documented below.
func (o ClusterOutput) Logging() ClusterLoggingPtrOutput {
return o.ApplyT(func(v *Cluster) ClusterLoggingPtrOutput { return v.Logging }).(ClusterLoggingPtrOutput)
}
// The name of the maintenance track for the restored cluster. When you take a snapshot, the snapshot inherits the MaintenanceTrack value from the cluster. The snapshot might be on a different track than the cluster that was the source for the snapshot. For example, suppose that you take a snapshot of a cluster that is on the current track and then change the cluster to be on the trailing track. In this case, the snapshot and the source cluster are on different tracks. Default value is `current`.
func (o ClusterOutput) MaintenanceTrackName() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.MaintenanceTrackName }).(pulumi.StringPtrOutput)
}
// The default number of days to retain a manual snapshot. If the value is -1, the snapshot is retained indefinitely. This setting doesn't change the retention period of existing snapshots. Valid values are between `-1` and `3653`. Default value is `-1`.
func (o ClusterOutput) ManualSnapshotRetentionPeriod() pulumi.IntPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.IntPtrOutput { return v.ManualSnapshotRetentionPeriod }).(pulumi.IntPtrOutput)
}
// Password for the master DB user.
// Note that this may show up in logs, and it will be stored in the state file. Password must contain at least 8 chars and
// contain at least one uppercase letter, one lowercase letter, and one number.
func (o ClusterOutput) MasterPassword() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.MasterPassword }).(pulumi.StringPtrOutput)
}
// Username for the master DB user.
func (o ClusterOutput) MasterUsername() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.MasterUsername }).(pulumi.StringPtrOutput)
}
// The node type to be provisioned for the cluster.
func (o ClusterOutput) NodeType() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.NodeType }).(pulumi.StringOutput)
}
// The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. Default is 1.
func (o ClusterOutput) NumberOfNodes() pulumi.IntPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.IntPtrOutput { return v.NumberOfNodes }).(pulumi.IntPtrOutput)
}
// The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
func (o ClusterOutput) OwnerAccount() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.OwnerAccount }).(pulumi.StringPtrOutput)
}
// The port number on which the cluster accepts incoming connections. Valid values are between `1115` and `65535`.
// The cluster is accessible only via the JDBC and ODBC connection strings.
// Part of the connection string requires the port on which the cluster will listen for incoming connections.
// Default port is `5439`.
func (o ClusterOutput) Port() pulumi.IntPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.IntPtrOutput { return v.Port }).(pulumi.IntPtrOutput)
}
// The weekly time range (in UTC) during which automated cluster maintenance can occur.
// Format: ddd:hh24:mi-ddd:hh24:mi
func (o ClusterOutput) PreferredMaintenanceWindow() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.PreferredMaintenanceWindow }).(pulumi.StringOutput)
}
// If true, the cluster can be accessed from a public network. Default is `true`.
func (o ClusterOutput) PubliclyAccessible() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.PubliclyAccessible }).(pulumi.BoolPtrOutput)
}
// Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If true , a final cluster snapshot is not created. If false , a final cluster snapshot is created before the cluster is deleted. Default is false.
func (o ClusterOutput) SkipFinalSnapshot() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.SkipFinalSnapshot }).(pulumi.BoolPtrOutput)
}
// The name of the cluster the source snapshot was created from.
func (o ClusterOutput) SnapshotClusterIdentifier() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.SnapshotClusterIdentifier }).(pulumi.StringPtrOutput)
}
// Configuration of automatic copy of snapshots from one region to another. Documented below.
func (o ClusterOutput) SnapshotCopy() ClusterSnapshotCopyPtrOutput {
return o.ApplyT(func(v *Cluster) ClusterSnapshotCopyPtrOutput { return v.SnapshotCopy }).(ClusterSnapshotCopyPtrOutput)
}
// The name of the snapshot from which to create the new cluster.
func (o ClusterOutput) SnapshotIdentifier() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringPtrOutput { return v.SnapshotIdentifier }).(pulumi.StringPtrOutput)
}
// A map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
func (o ClusterOutput) Tags() pulumi.StringMapOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
}
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
func (o ClusterOutput) TagsAll() pulumi.StringMapOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput)
}
// A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
func (o ClusterOutput) VpcSecurityGroupIds() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringArrayOutput { return v.VpcSecurityGroupIds }).(pulumi.StringArrayOutput)
}
type ClusterArrayOutput struct{ *pulumi.OutputState }
func (ClusterArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Cluster)(nil)).Elem()
}
func (o ClusterArrayOutput) ToClusterArrayOutput() ClusterArrayOutput {
return o
}
func (o ClusterArrayOutput) ToClusterArrayOutputWithContext(ctx context.Context) ClusterArrayOutput {
return o
}
func (o ClusterArrayOutput) Index(i pulumi.IntInput) ClusterOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Cluster {
return vs[0].([]*Cluster)[vs[1].(int)]
}).(ClusterOutput)
}
type ClusterMapOutput struct{ *pulumi.OutputState }
func (ClusterMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Cluster)(nil)).Elem()
}
func (o ClusterMapOutput) ToClusterMapOutput() ClusterMapOutput {
return o
}
func (o ClusterMapOutput) ToClusterMapOutputWithContext(ctx context.Context) ClusterMapOutput {
return o
}
func (o ClusterMapOutput) MapIndex(k pulumi.StringInput) ClusterOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Cluster {
return vs[0].(map[string]*Cluster)[vs[1].(string)]
}).(ClusterOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*ClusterInput)(nil)).Elem(), &Cluster{})
pulumi.RegisterInputType(reflect.TypeOf((*ClusterArrayInput)(nil)).Elem(), ClusterArray{})
pulumi.RegisterInputType(reflect.TypeOf((*ClusterMapInput)(nil)).Elem(), ClusterMap{})
pulumi.RegisterOutputType(ClusterOutput{})
pulumi.RegisterOutputType(ClusterArrayOutput{})
pulumi.RegisterOutputType(ClusterMapOutput{})
}