generated from pulumi/pulumi-tf-provider-boilerplate
/
cluster.go
1332 lines (1227 loc) · 78.1 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
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// 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 ehpc
import (
"context"
"reflect"
"github.com/pkg/errors"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Provides a Ehpc Cluster resource.
//
// For information about Ehpc Cluster and how to use it, see [What is Cluster](https://www.alibabacloud.com/help/e-hpc/latest/createcluster).
//
// > **NOTE:** Available in v1.173.0+.
//
// ## Example Usage
//
// # Basic Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-alicloud/sdk/go/alicloud"
// "github.com/pulumi/pulumi-alicloud/sdk/go/alicloud/ecs"
// "github.com/pulumi/pulumi-alicloud/sdk/go/alicloud/vpc"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
// "github.com/rhysmdnz/pulumi-alicloud/sdk/go/alicloud"
// "github.com/rhysmdnz/pulumi-alicloud/sdk/go/alicloud/ecs"
// "github.com/rhysmdnz/pulumi-alicloud/sdk/go/alicloud/ehpc"
// "github.com/rhysmdnz/pulumi-alicloud/sdk/go/alicloud/nas"
// "github.com/rhysmdnz/pulumi-alicloud/sdk/go/alicloud/vpc"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// defaultZones, err := alicloud.GetZones(ctx, &GetZonesArgs{
// AvailableResourceCreation: pulumi.StringRef("VSwitch"),
// }, nil)
// if err != nil {
// return err
// }
// defaultNetworks, err := vpc.GetNetworks(ctx, &vpc.GetNetworksArgs{
// NameRegex: pulumi.StringRef("default-NODELETING"),
// }, nil)
// if err != nil {
// return err
// }
// defaultSwitches, err := vpc.GetSwitches(ctx, &vpc.GetSwitchesArgs{
// VpcId: pulumi.StringRef(defaultNetworks.Ids[0]),
// ZoneId: pulumi.StringRef(defaultZones.Zones[0].Id),
// }, nil)
// if err != nil {
// return err
// }
// defaultInstanceTypes, err := ecs.GetInstanceTypes(ctx, &ecs.GetInstanceTypesArgs{
// AvailabilityZone: pulumi.StringRef(defaultZones.Zones[0].Id),
// }, nil)
// if err != nil {
// return err
// }
// cfg := config.New(ctx, "")
// storageType := "Performance"
// if param := cfg.Get("storageType"); param != "" {
// storageType = param
// }
// defaultFileSystem, err := nas.NewFileSystem(ctx, "defaultFileSystem", &nas.FileSystemArgs{
// StorageType: pulumi.String(storageType),
// ProtocolType: pulumi.String("NFS"),
// })
// if err != nil {
// return err
// }
// defaultMountTarget, err := nas.NewMountTarget(ctx, "defaultMountTarget", &nas.MountTargetArgs{
// FileSystemId: defaultFileSystem.ID(),
// AccessGroupName: pulumi.String("DEFAULT_VPC_GROUP_NAME"),
// VswitchId: pulumi.String(defaultSwitches.Ids[0]),
// })
// if err != nil {
// return err
// }
// defaultImages, err := ecs.GetImages(ctx, &ecs.GetImagesArgs{
// NameRegex: pulumi.StringRef("^centos_7_6_x64*"),
// Owners: pulumi.StringRef("system"),
// }, nil)
// if err != nil {
// return err
// }
// _, err = ehpc.NewCluster(ctx, "defaultCluster", &ehpc.ClusterArgs{
// ClusterName: pulumi.String("example_value"),
// DeployMode: pulumi.String("Simple"),
// Description: pulumi.String("example_description"),
// HaEnable: pulumi.Bool(false),
// ImageId: pulumi.String(defaultImages.Images[0].Id),
// ImageOwnerAlias: pulumi.String("system"),
// VolumeProtocol: pulumi.String("nfs"),
// VolumeId: defaultFileSystem.ID(),
// VolumeMountpoint: defaultMountTarget.MountTargetDomain,
// ComputeCount: pulumi.Int(1),
// ComputeInstanceType: pulumi.String(defaultInstanceTypes.InstanceTypes[0].Id),
// LoginCount: pulumi.Int(1),
// LoginInstanceType: pulumi.String(defaultInstanceTypes.InstanceTypes[0].Id),
// ManagerCount: pulumi.Int(1),
// ManagerInstanceType: pulumi.String(defaultInstanceTypes.InstanceTypes[0].Id),
// OsTag: pulumi.String("CentOS_7.6_64"),
// SchedulerType: pulumi.String("pbs"),
// Password: pulumi.String("your-password123"),
// VswitchId: pulumi.String(defaultSwitches.Ids[0]),
// VpcId: pulumi.String(defaultNetworks.Ids[0]),
// ZoneId: pulumi.String(defaultZones.Zones[0].Id),
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// Ehpc Cluster can be imported using the id, e.g.
//
// ```sh
//
// $ pulumi import alicloud:ehpc/cluster:Cluster example <id>
//
// ```
type Cluster struct {
pulumi.CustomResourceState
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
AccountType pulumi.StringOutput `pulumi:"accountType"`
// The additional volumes. See the following `Block additionalVolumes`.
AdditionalVolumes ClusterAdditionalVolumeArrayOutput `pulumi:"additionalVolumes"`
// The application. See the following `Block application`.
Applications ClusterApplicationArrayOutput `pulumi:"applications"`
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
AutoRenew pulumi.BoolPtrOutput `pulumi:"autoRenew"`
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
AutoRenewPeriod pulumi.IntPtrOutput `pulumi:"autoRenewPeriod"`
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
ClientVersion pulumi.StringOutput `pulumi:"clientVersion"`
// The name of the cluster. The name must be `2` to `64` characters in length.
ClusterName pulumi.StringOutput `pulumi:"clusterName"`
// The version of the cluster. Default value: `1.0`.
ClusterVersion pulumi.StringOutput `pulumi:"clusterVersion"`
// The number of the compute nodes. Valid values: `1` to `99`.
ComputeCount pulumi.IntOutput `pulumi:"computeCount"`
// Specifies whether the compute nodes support hyper-threading. Default value: `true`.
ComputeEnableHt pulumi.BoolPtrOutput `pulumi:"computeEnableHt"`
// The instance type of the compute nodes.
ComputeInstanceType pulumi.StringOutput `pulumi:"computeInstanceType"`
// The maximum hourly price of the compute nodes. A maximum of three decimal places can be used in the value of the parameter. The parameter is valid only when the ComputeSpotStrategy parameter is set to SpotWithPriceLimit.
ComputeSpotPriceLimit pulumi.StringPtrOutput `pulumi:"computeSpotPriceLimit"`
// The bidding method of the compute nodes. Default value: `NoSpot`. Valid values:
// - `NoSpot`: The compute nodes are pay-as-you-go instances.
// - `SpotWithPriceLimit`: The compute nodes are preemptible instances that have a user-defined maximum hourly price.
// - `SpotAsPriceGo`: The compute nodes are preemptible instances for which the market price at the time of purchase is used as the bid price.
ComputeSpotStrategy pulumi.StringPtrOutput `pulumi:"computeSpotStrategy"`
// The mode in which the cluster is deployed. Valid values: `Standard`, `Simple`, `Tiny`. Default value: Standard.
// - `Standard`: An account node, a scheduling node, a logon node, and multiple compute nodes are separately deployed.
// - `Simple`: A management node, a logon node, and multiple compute nodes are deployed. The management node consists of an account node and a scheduling node. The logon node and compute nodes are separately deployed.
// - `Tiny`: A management node and multiple compute nodes are deployed. The management node consists of an account node, a scheduling node, and a logon node. The compute nodes are separately deployed.
DeployMode pulumi.StringOutput `pulumi:"deployMode"`
// The description of the cluster. The description must be `2` to `256` characters in length. It cannot start with `http://` or `https://`.
Description pulumi.StringOutput `pulumi:"description"`
// The domain name of the on-premises cluster. This parameter takes effect only when the AccoutType parameter is set to Idap.
Domain pulumi.StringPtrOutput `pulumi:"domain"`
// The billing method of the nodes.
EcsChargeType pulumi.StringOutput `pulumi:"ecsChargeType"`
// The version of E-HPC. By default, the parameter is set to the latest version number.
EhpcVersion pulumi.StringOutput `pulumi:"ehpcVersion"`
// Specifies whether to enable the high availability feature. Default value: `false`. **Note:** If high availability is enabled, a primary management node and a secondary management node are used.
HaEnable pulumi.BoolOutput `pulumi:"haEnable"`
// The ID of the image.
ImageId pulumi.StringOutput `pulumi:"imageId"`
// The type of the image. Valid values: `others`, `self`, `system`, `marketplace`. Default value: `system`.
ImageOwnerAlias pulumi.StringOutput `pulumi:"imageOwnerAlias"`
// The URL of the job files that are uploaded to an Object Storage Service (OSS) bucket.
InputFileUrl pulumi.StringPtrOutput `pulumi:"inputFileUrl"`
// Specifies whether to enable auto scaling. Default value: `false`.
IsComputeEss pulumi.BoolPtrOutput `pulumi:"isComputeEss"`
// The queue of the nodes to which the additional file system is attached.
JobQueue pulumi.StringPtrOutput `pulumi:"jobQueue"`
// The name of the AccessKey pair.
KeyPairName pulumi.StringPtrOutput `pulumi:"keyPairName"`
// The number of the logon nodes. Valid values: `1`.
LoginCount pulumi.IntOutput `pulumi:"loginCount"`
// The instance type of the logon nodes.
LoginInstanceType pulumi.StringOutput `pulumi:"loginInstanceType"`
// The number of the management nodes. Valid values: 1 and 2.
ManagerCount pulumi.IntOutput `pulumi:"managerCount"`
// The instance type of the management nodes.
ManagerInstanceType pulumi.StringOutput `pulumi:"managerInstanceType"`
// The image tag of the operating system.
OsTag pulumi.StringOutput `pulumi:"osTag"`
// The root password of the logon node. The password must be 8 to 30 characters in length and contain at least three of the following items: uppercase letters, lowercase letters, digits, and special characters. The password can contain the following special characters: `( ) ~ ! @ # $ % ^ & * - + = { } [ ] : ; ‘ < > , . ? /`. You must specify either `password` or `keyPairName`. If both are specified, the Password parameter prevails.
Password pulumi.StringPtrOutput `pulumi:"password"`
// The duration of the subscription. The unit of the duration is specified by the `periodUnit` parameter. Default value: `1`.
// * If you set PriceUnit to Year, the valid values of the Period parameter are 1, 2, and 3.
// * If you set PriceUnit to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
// * If you set PriceUnit to Hour, the valid value of the Period parameter is 1.
Period pulumi.IntPtrOutput `pulumi:"period"`
// The unit of the subscription duration. Valid values: `Year`, `Month`, `Hour`. Default value: `Month`.
PeriodUnit pulumi.StringPtrOutput `pulumi:"periodUnit"`
// The mode configurations of the plug-in. This parameter takes effect only when the SchedulerType parameter is set to custom. The value must be a JSON string. The parameter contains the following parameters: pluginMod, pluginLocalPath, and pluginOssPath.
// - pluginMod: the mode of the plug-in. The following modes are supported:
// - oss: The plug-in is downloaded and decompressed from OSS to a local path. The local path is specified by the pluginLocalPath parameter.
// - image: By default, the plug-in is stored in a pre-defined local path. The local path is specified by the pluginLocalPath parameter.
// - pluginLocalPath: the local path where the plug-in is stored. We recommend that you select a shared directory in oss mode and a non-shared directory in image mode.
// - pluginOssPath: the remote path where the plug-in is stored in OSS. This parameter takes effect only when the pluginMod parameter is set to oss.
Plugin pulumi.StringPtrOutput `pulumi:"plugin"`
// The post install script. See the following `Block postInstallScript`.
PostInstallScripts ClusterPostInstallScriptArrayOutput `pulumi:"postInstallScripts"`
// The node of the RAM role.
RamNodeTypes pulumi.StringArrayOutput `pulumi:"ramNodeTypes"`
// The name of the Resource Access Management (RAM) role.
RamRoleName pulumi.StringPtrOutput `pulumi:"ramRoleName"`
// The release instance. Valid values: `true`.
ReleaseInstance pulumi.BoolPtrOutput `pulumi:"releaseInstance"`
// The remote directory to which the additional file system is mounted.
RemoteDirectory pulumi.StringOutput `pulumi:"remoteDirectory"`
// Specifies whether to enable Virtual Network Computing (VNC). Default value: `false`.
RemoteVisEnable pulumi.BoolPtrOutput `pulumi:"remoteVisEnable"`
// The ID of the resource group.
ResourceGroupId pulumi.StringPtrOutput `pulumi:"resourceGroupId"`
// The ID of the Super Computing Cluster (SCC) instance. If you specify the parameter, the SCC instance is moved to a new SCC cluster.
SccClusterId pulumi.StringOutput `pulumi:"sccClusterId"`
// The type of the scheduler. Valid values: `pbs`, `slurm`, `opengridscheduler` and `deadline`. Default value: `pbs`.
SchedulerType pulumi.StringOutput `pulumi:"schedulerType"`
// The ID of the security group to which the cluster belongs.
SecurityGroupId pulumi.StringOutput `pulumi:"securityGroupId"`
// If you do not use an existing security group, set the parameter to the name of a new security group. A default policy is applied to the new security group.
SecurityGroupName pulumi.StringPtrOutput `pulumi:"securityGroupName"`
// The status of the resource.
Status pulumi.StringOutput `pulumi:"status"`
// The performance level of the ESSD that is used as the system disk. Default value: `PL1` For more information, see [ESSDs](https://www.alibabacloud.com/help/en/elastic-compute-service/latest/essds). Valid values:
// * `PL0`: A single ESSD can deliver up to 10,000 random read/write IOPS.
// * `PL1`: A single ESSD can deliver up to 50,000 random read/write IOPS.
// * `PL2`: A single ESSD can deliver up to 100,000 random read/write IOPS.
// * `PL3`: A single ESSD can deliver up to 1,000,000 random read/write IOPS.
SystemDiskLevel pulumi.StringPtrOutput `pulumi:"systemDiskLevel"`
// The size of the system disk. Unit: `GB`. Valid values: `40` to `500`. Default value: `40`.
SystemDiskSize pulumi.IntPtrOutput `pulumi:"systemDiskSize"`
// The type of the system disk. Valid values: `cloudEfficiency`, `cloudSsd`, `cloudEssd` or `cloud`. Default value: `cloudSsd`.
SystemDiskType pulumi.StringPtrOutput `pulumi:"systemDiskType"`
// The ID of the additional file system.
VolumeId pulumi.StringOutput `pulumi:"volumeId"`
// The mount options of the file system.
VolumeMountOption pulumi.StringPtrOutput `pulumi:"volumeMountOption"`
// The mount target of the additional file system.
VolumeMountpoint pulumi.StringOutput `pulumi:"volumeMountpoint"`
// The type of the protocol that is used by the additional file system. Valid values: `NFS`, `SMB`. Default value: `NFS`
VolumeProtocol pulumi.StringOutput `pulumi:"volumeProtocol"`
// The type of the additional shared storage. Only NAS file systems are supported.
VolumeType pulumi.StringOutput `pulumi:"volumeType"`
// The ID of the virtual private cloud (VPC) to which the cluster belongs.
VpcId pulumi.StringOutput `pulumi:"vpcId"`
// The ID of the vSwitch. E-HPC supports only VPC networks.
VswitchId pulumi.StringOutput `pulumi:"vswitchId"`
// Specifies whether not to install the agent. Default value: `false`.
WithoutAgent pulumi.BoolPtrOutput `pulumi:"withoutAgent"`
// Specifies whether the logon node uses an elastic IP address (EIP). Default value: `false`.
WithoutElasticIp pulumi.BoolPtrOutput `pulumi:"withoutElasticIp"`
// The ID of the zone.
ZoneId pulumi.StringOutput `pulumi:"zoneId"`
}
// 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.ClusterName == nil {
return nil, errors.New("invalid value for required argument 'ClusterName'")
}
if args.ComputeCount == nil {
return nil, errors.New("invalid value for required argument 'ComputeCount'")
}
if args.ComputeInstanceType == nil {
return nil, errors.New("invalid value for required argument 'ComputeInstanceType'")
}
if args.LoginCount == nil {
return nil, errors.New("invalid value for required argument 'LoginCount'")
}
if args.LoginInstanceType == nil {
return nil, errors.New("invalid value for required argument 'LoginInstanceType'")
}
if args.ManagerInstanceType == nil {
return nil, errors.New("invalid value for required argument 'ManagerInstanceType'")
}
if args.OsTag == nil {
return nil, errors.New("invalid value for required argument 'OsTag'")
}
opts = pkgResourceDefaultOpts(opts)
var resource Cluster
err := ctx.RegisterResource("alicloud:ehpc/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("alicloud:ehpc/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 {
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
AccountType *string `pulumi:"accountType"`
// The additional volumes. See the following `Block additionalVolumes`.
AdditionalVolumes []ClusterAdditionalVolume `pulumi:"additionalVolumes"`
// The application. See the following `Block application`.
Applications []ClusterApplication `pulumi:"applications"`
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
AutoRenew *bool `pulumi:"autoRenew"`
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
AutoRenewPeriod *int `pulumi:"autoRenewPeriod"`
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
ClientVersion *string `pulumi:"clientVersion"`
// The name of the cluster. The name must be `2` to `64` characters in length.
ClusterName *string `pulumi:"clusterName"`
// The version of the cluster. Default value: `1.0`.
ClusterVersion *string `pulumi:"clusterVersion"`
// The number of the compute nodes. Valid values: `1` to `99`.
ComputeCount *int `pulumi:"computeCount"`
// Specifies whether the compute nodes support hyper-threading. Default value: `true`.
ComputeEnableHt *bool `pulumi:"computeEnableHt"`
// The instance type of the compute nodes.
ComputeInstanceType *string `pulumi:"computeInstanceType"`
// The maximum hourly price of the compute nodes. A maximum of three decimal places can be used in the value of the parameter. The parameter is valid only when the ComputeSpotStrategy parameter is set to SpotWithPriceLimit.
ComputeSpotPriceLimit *string `pulumi:"computeSpotPriceLimit"`
// The bidding method of the compute nodes. Default value: `NoSpot`. Valid values:
// - `NoSpot`: The compute nodes are pay-as-you-go instances.
// - `SpotWithPriceLimit`: The compute nodes are preemptible instances that have a user-defined maximum hourly price.
// - `SpotAsPriceGo`: The compute nodes are preemptible instances for which the market price at the time of purchase is used as the bid price.
ComputeSpotStrategy *string `pulumi:"computeSpotStrategy"`
// The mode in which the cluster is deployed. Valid values: `Standard`, `Simple`, `Tiny`. Default value: Standard.
// - `Standard`: An account node, a scheduling node, a logon node, and multiple compute nodes are separately deployed.
// - `Simple`: A management node, a logon node, and multiple compute nodes are deployed. The management node consists of an account node and a scheduling node. The logon node and compute nodes are separately deployed.
// - `Tiny`: A management node and multiple compute nodes are deployed. The management node consists of an account node, a scheduling node, and a logon node. The compute nodes are separately deployed.
DeployMode *string `pulumi:"deployMode"`
// The description of the cluster. The description must be `2` to `256` characters in length. It cannot start with `http://` or `https://`.
Description *string `pulumi:"description"`
// The domain name of the on-premises cluster. This parameter takes effect only when the AccoutType parameter is set to Idap.
Domain *string `pulumi:"domain"`
// The billing method of the nodes.
EcsChargeType *string `pulumi:"ecsChargeType"`
// The version of E-HPC. By default, the parameter is set to the latest version number.
EhpcVersion *string `pulumi:"ehpcVersion"`
// Specifies whether to enable the high availability feature. Default value: `false`. **Note:** If high availability is enabled, a primary management node and a secondary management node are used.
HaEnable *bool `pulumi:"haEnable"`
// The ID of the image.
ImageId *string `pulumi:"imageId"`
// The type of the image. Valid values: `others`, `self`, `system`, `marketplace`. Default value: `system`.
ImageOwnerAlias *string `pulumi:"imageOwnerAlias"`
// The URL of the job files that are uploaded to an Object Storage Service (OSS) bucket.
InputFileUrl *string `pulumi:"inputFileUrl"`
// Specifies whether to enable auto scaling. Default value: `false`.
IsComputeEss *bool `pulumi:"isComputeEss"`
// The queue of the nodes to which the additional file system is attached.
JobQueue *string `pulumi:"jobQueue"`
// The name of the AccessKey pair.
KeyPairName *string `pulumi:"keyPairName"`
// The number of the logon nodes. Valid values: `1`.
LoginCount *int `pulumi:"loginCount"`
// The instance type of the logon nodes.
LoginInstanceType *string `pulumi:"loginInstanceType"`
// The number of the management nodes. Valid values: 1 and 2.
ManagerCount *int `pulumi:"managerCount"`
// The instance type of the management nodes.
ManagerInstanceType *string `pulumi:"managerInstanceType"`
// The image tag of the operating system.
OsTag *string `pulumi:"osTag"`
// The root password of the logon node. The password must be 8 to 30 characters in length and contain at least three of the following items: uppercase letters, lowercase letters, digits, and special characters. The password can contain the following special characters: `( ) ~ ! @ # $ % ^ & * - + = { } [ ] : ; ‘ < > , . ? /`. You must specify either `password` or `keyPairName`. If both are specified, the Password parameter prevails.
Password *string `pulumi:"password"`
// The duration of the subscription. The unit of the duration is specified by the `periodUnit` parameter. Default value: `1`.
// * If you set PriceUnit to Year, the valid values of the Period parameter are 1, 2, and 3.
// * If you set PriceUnit to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
// * If you set PriceUnit to Hour, the valid value of the Period parameter is 1.
Period *int `pulumi:"period"`
// The unit of the subscription duration. Valid values: `Year`, `Month`, `Hour`. Default value: `Month`.
PeriodUnit *string `pulumi:"periodUnit"`
// The mode configurations of the plug-in. This parameter takes effect only when the SchedulerType parameter is set to custom. The value must be a JSON string. The parameter contains the following parameters: pluginMod, pluginLocalPath, and pluginOssPath.
// - pluginMod: the mode of the plug-in. The following modes are supported:
// - oss: The plug-in is downloaded and decompressed from OSS to a local path. The local path is specified by the pluginLocalPath parameter.
// - image: By default, the plug-in is stored in a pre-defined local path. The local path is specified by the pluginLocalPath parameter.
// - pluginLocalPath: the local path where the plug-in is stored. We recommend that you select a shared directory in oss mode and a non-shared directory in image mode.
// - pluginOssPath: the remote path where the plug-in is stored in OSS. This parameter takes effect only when the pluginMod parameter is set to oss.
Plugin *string `pulumi:"plugin"`
// The post install script. See the following `Block postInstallScript`.
PostInstallScripts []ClusterPostInstallScript `pulumi:"postInstallScripts"`
// The node of the RAM role.
RamNodeTypes []string `pulumi:"ramNodeTypes"`
// The name of the Resource Access Management (RAM) role.
RamRoleName *string `pulumi:"ramRoleName"`
// The release instance. Valid values: `true`.
ReleaseInstance *bool `pulumi:"releaseInstance"`
// The remote directory to which the additional file system is mounted.
RemoteDirectory *string `pulumi:"remoteDirectory"`
// Specifies whether to enable Virtual Network Computing (VNC). Default value: `false`.
RemoteVisEnable *bool `pulumi:"remoteVisEnable"`
// The ID of the resource group.
ResourceGroupId *string `pulumi:"resourceGroupId"`
// The ID of the Super Computing Cluster (SCC) instance. If you specify the parameter, the SCC instance is moved to a new SCC cluster.
SccClusterId *string `pulumi:"sccClusterId"`
// The type of the scheduler. Valid values: `pbs`, `slurm`, `opengridscheduler` and `deadline`. Default value: `pbs`.
SchedulerType *string `pulumi:"schedulerType"`
// The ID of the security group to which the cluster belongs.
SecurityGroupId *string `pulumi:"securityGroupId"`
// If you do not use an existing security group, set the parameter to the name of a new security group. A default policy is applied to the new security group.
SecurityGroupName *string `pulumi:"securityGroupName"`
// The status of the resource.
Status *string `pulumi:"status"`
// The performance level of the ESSD that is used as the system disk. Default value: `PL1` For more information, see [ESSDs](https://www.alibabacloud.com/help/en/elastic-compute-service/latest/essds). Valid values:
// * `PL0`: A single ESSD can deliver up to 10,000 random read/write IOPS.
// * `PL1`: A single ESSD can deliver up to 50,000 random read/write IOPS.
// * `PL2`: A single ESSD can deliver up to 100,000 random read/write IOPS.
// * `PL3`: A single ESSD can deliver up to 1,000,000 random read/write IOPS.
SystemDiskLevel *string `pulumi:"systemDiskLevel"`
// The size of the system disk. Unit: `GB`. Valid values: `40` to `500`. Default value: `40`.
SystemDiskSize *int `pulumi:"systemDiskSize"`
// The type of the system disk. Valid values: `cloudEfficiency`, `cloudSsd`, `cloudEssd` or `cloud`. Default value: `cloudSsd`.
SystemDiskType *string `pulumi:"systemDiskType"`
// The ID of the additional file system.
VolumeId *string `pulumi:"volumeId"`
// The mount options of the file system.
VolumeMountOption *string `pulumi:"volumeMountOption"`
// The mount target of the additional file system.
VolumeMountpoint *string `pulumi:"volumeMountpoint"`
// The type of the protocol that is used by the additional file system. Valid values: `NFS`, `SMB`. Default value: `NFS`
VolumeProtocol *string `pulumi:"volumeProtocol"`
// The type of the additional shared storage. Only NAS file systems are supported.
VolumeType *string `pulumi:"volumeType"`
// The ID of the virtual private cloud (VPC) to which the cluster belongs.
VpcId *string `pulumi:"vpcId"`
// The ID of the vSwitch. E-HPC supports only VPC networks.
VswitchId *string `pulumi:"vswitchId"`
// Specifies whether not to install the agent. Default value: `false`.
WithoutAgent *bool `pulumi:"withoutAgent"`
// Specifies whether the logon node uses an elastic IP address (EIP). Default value: `false`.
WithoutElasticIp *bool `pulumi:"withoutElasticIp"`
// The ID of the zone.
ZoneId *string `pulumi:"zoneId"`
}
type ClusterState struct {
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
AccountType pulumi.StringPtrInput
// The additional volumes. See the following `Block additionalVolumes`.
AdditionalVolumes ClusterAdditionalVolumeArrayInput
// The application. See the following `Block application`.
Applications ClusterApplicationArrayInput
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
AutoRenew pulumi.BoolPtrInput
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
AutoRenewPeriod pulumi.IntPtrInput
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
ClientVersion pulumi.StringPtrInput
// The name of the cluster. The name must be `2` to `64` characters in length.
ClusterName pulumi.StringPtrInput
// The version of the cluster. Default value: `1.0`.
ClusterVersion pulumi.StringPtrInput
// The number of the compute nodes. Valid values: `1` to `99`.
ComputeCount pulumi.IntPtrInput
// Specifies whether the compute nodes support hyper-threading. Default value: `true`.
ComputeEnableHt pulumi.BoolPtrInput
// The instance type of the compute nodes.
ComputeInstanceType pulumi.StringPtrInput
// The maximum hourly price of the compute nodes. A maximum of three decimal places can be used in the value of the parameter. The parameter is valid only when the ComputeSpotStrategy parameter is set to SpotWithPriceLimit.
ComputeSpotPriceLimit pulumi.StringPtrInput
// The bidding method of the compute nodes. Default value: `NoSpot`. Valid values:
// - `NoSpot`: The compute nodes are pay-as-you-go instances.
// - `SpotWithPriceLimit`: The compute nodes are preemptible instances that have a user-defined maximum hourly price.
// - `SpotAsPriceGo`: The compute nodes are preemptible instances for which the market price at the time of purchase is used as the bid price.
ComputeSpotStrategy pulumi.StringPtrInput
// The mode in which the cluster is deployed. Valid values: `Standard`, `Simple`, `Tiny`. Default value: Standard.
// - `Standard`: An account node, a scheduling node, a logon node, and multiple compute nodes are separately deployed.
// - `Simple`: A management node, a logon node, and multiple compute nodes are deployed. The management node consists of an account node and a scheduling node. The logon node and compute nodes are separately deployed.
// - `Tiny`: A management node and multiple compute nodes are deployed. The management node consists of an account node, a scheduling node, and a logon node. The compute nodes are separately deployed.
DeployMode pulumi.StringPtrInput
// The description of the cluster. The description must be `2` to `256` characters in length. It cannot start with `http://` or `https://`.
Description pulumi.StringPtrInput
// The domain name of the on-premises cluster. This parameter takes effect only when the AccoutType parameter is set to Idap.
Domain pulumi.StringPtrInput
// The billing method of the nodes.
EcsChargeType pulumi.StringPtrInput
// The version of E-HPC. By default, the parameter is set to the latest version number.
EhpcVersion pulumi.StringPtrInput
// Specifies whether to enable the high availability feature. Default value: `false`. **Note:** If high availability is enabled, a primary management node and a secondary management node are used.
HaEnable pulumi.BoolPtrInput
// The ID of the image.
ImageId pulumi.StringPtrInput
// The type of the image. Valid values: `others`, `self`, `system`, `marketplace`. Default value: `system`.
ImageOwnerAlias pulumi.StringPtrInput
// The URL of the job files that are uploaded to an Object Storage Service (OSS) bucket.
InputFileUrl pulumi.StringPtrInput
// Specifies whether to enable auto scaling. Default value: `false`.
IsComputeEss pulumi.BoolPtrInput
// The queue of the nodes to which the additional file system is attached.
JobQueue pulumi.StringPtrInput
// The name of the AccessKey pair.
KeyPairName pulumi.StringPtrInput
// The number of the logon nodes. Valid values: `1`.
LoginCount pulumi.IntPtrInput
// The instance type of the logon nodes.
LoginInstanceType pulumi.StringPtrInput
// The number of the management nodes. Valid values: 1 and 2.
ManagerCount pulumi.IntPtrInput
// The instance type of the management nodes.
ManagerInstanceType pulumi.StringPtrInput
// The image tag of the operating system.
OsTag pulumi.StringPtrInput
// The root password of the logon node. The password must be 8 to 30 characters in length and contain at least three of the following items: uppercase letters, lowercase letters, digits, and special characters. The password can contain the following special characters: `( ) ~ ! @ # $ % ^ & * - + = { } [ ] : ; ‘ < > , . ? /`. You must specify either `password` or `keyPairName`. If both are specified, the Password parameter prevails.
Password pulumi.StringPtrInput
// The duration of the subscription. The unit of the duration is specified by the `periodUnit` parameter. Default value: `1`.
// * If you set PriceUnit to Year, the valid values of the Period parameter are 1, 2, and 3.
// * If you set PriceUnit to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
// * If you set PriceUnit to Hour, the valid value of the Period parameter is 1.
Period pulumi.IntPtrInput
// The unit of the subscription duration. Valid values: `Year`, `Month`, `Hour`. Default value: `Month`.
PeriodUnit pulumi.StringPtrInput
// The mode configurations of the plug-in. This parameter takes effect only when the SchedulerType parameter is set to custom. The value must be a JSON string. The parameter contains the following parameters: pluginMod, pluginLocalPath, and pluginOssPath.
// - pluginMod: the mode of the plug-in. The following modes are supported:
// - oss: The plug-in is downloaded and decompressed from OSS to a local path. The local path is specified by the pluginLocalPath parameter.
// - image: By default, the plug-in is stored in a pre-defined local path. The local path is specified by the pluginLocalPath parameter.
// - pluginLocalPath: the local path where the plug-in is stored. We recommend that you select a shared directory in oss mode and a non-shared directory in image mode.
// - pluginOssPath: the remote path where the plug-in is stored in OSS. This parameter takes effect only when the pluginMod parameter is set to oss.
Plugin pulumi.StringPtrInput
// The post install script. See the following `Block postInstallScript`.
PostInstallScripts ClusterPostInstallScriptArrayInput
// The node of the RAM role.
RamNodeTypes pulumi.StringArrayInput
// The name of the Resource Access Management (RAM) role.
RamRoleName pulumi.StringPtrInput
// The release instance. Valid values: `true`.
ReleaseInstance pulumi.BoolPtrInput
// The remote directory to which the additional file system is mounted.
RemoteDirectory pulumi.StringPtrInput
// Specifies whether to enable Virtual Network Computing (VNC). Default value: `false`.
RemoteVisEnable pulumi.BoolPtrInput
// The ID of the resource group.
ResourceGroupId pulumi.StringPtrInput
// The ID of the Super Computing Cluster (SCC) instance. If you specify the parameter, the SCC instance is moved to a new SCC cluster.
SccClusterId pulumi.StringPtrInput
// The type of the scheduler. Valid values: `pbs`, `slurm`, `opengridscheduler` and `deadline`. Default value: `pbs`.
SchedulerType pulumi.StringPtrInput
// The ID of the security group to which the cluster belongs.
SecurityGroupId pulumi.StringPtrInput
// If you do not use an existing security group, set the parameter to the name of a new security group. A default policy is applied to the new security group.
SecurityGroupName pulumi.StringPtrInput
// The status of the resource.
Status pulumi.StringPtrInput
// The performance level of the ESSD that is used as the system disk. Default value: `PL1` For more information, see [ESSDs](https://www.alibabacloud.com/help/en/elastic-compute-service/latest/essds). Valid values:
// * `PL0`: A single ESSD can deliver up to 10,000 random read/write IOPS.
// * `PL1`: A single ESSD can deliver up to 50,000 random read/write IOPS.
// * `PL2`: A single ESSD can deliver up to 100,000 random read/write IOPS.
// * `PL3`: A single ESSD can deliver up to 1,000,000 random read/write IOPS.
SystemDiskLevel pulumi.StringPtrInput
// The size of the system disk. Unit: `GB`. Valid values: `40` to `500`. Default value: `40`.
SystemDiskSize pulumi.IntPtrInput
// The type of the system disk. Valid values: `cloudEfficiency`, `cloudSsd`, `cloudEssd` or `cloud`. Default value: `cloudSsd`.
SystemDiskType pulumi.StringPtrInput
// The ID of the additional file system.
VolumeId pulumi.StringPtrInput
// The mount options of the file system.
VolumeMountOption pulumi.StringPtrInput
// The mount target of the additional file system.
VolumeMountpoint pulumi.StringPtrInput
// The type of the protocol that is used by the additional file system. Valid values: `NFS`, `SMB`. Default value: `NFS`
VolumeProtocol pulumi.StringPtrInput
// The type of the additional shared storage. Only NAS file systems are supported.
VolumeType pulumi.StringPtrInput
// The ID of the virtual private cloud (VPC) to which the cluster belongs.
VpcId pulumi.StringPtrInput
// The ID of the vSwitch. E-HPC supports only VPC networks.
VswitchId pulumi.StringPtrInput
// Specifies whether not to install the agent. Default value: `false`.
WithoutAgent pulumi.BoolPtrInput
// Specifies whether the logon node uses an elastic IP address (EIP). Default value: `false`.
WithoutElasticIp pulumi.BoolPtrInput
// The ID of the zone.
ZoneId pulumi.StringPtrInput
}
func (ClusterState) ElementType() reflect.Type {
return reflect.TypeOf((*clusterState)(nil)).Elem()
}
type clusterArgs struct {
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
AccountType *string `pulumi:"accountType"`
// The additional volumes. See the following `Block additionalVolumes`.
AdditionalVolumes []ClusterAdditionalVolume `pulumi:"additionalVolumes"`
// The application. See the following `Block application`.
Applications []ClusterApplication `pulumi:"applications"`
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
AutoRenew *bool `pulumi:"autoRenew"`
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
AutoRenewPeriod *int `pulumi:"autoRenewPeriod"`
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
ClientVersion *string `pulumi:"clientVersion"`
// The name of the cluster. The name must be `2` to `64` characters in length.
ClusterName string `pulumi:"clusterName"`
// The version of the cluster. Default value: `1.0`.
ClusterVersion *string `pulumi:"clusterVersion"`
// The number of the compute nodes. Valid values: `1` to `99`.
ComputeCount int `pulumi:"computeCount"`
// Specifies whether the compute nodes support hyper-threading. Default value: `true`.
ComputeEnableHt *bool `pulumi:"computeEnableHt"`
// The instance type of the compute nodes.
ComputeInstanceType string `pulumi:"computeInstanceType"`
// The maximum hourly price of the compute nodes. A maximum of three decimal places can be used in the value of the parameter. The parameter is valid only when the ComputeSpotStrategy parameter is set to SpotWithPriceLimit.
ComputeSpotPriceLimit *string `pulumi:"computeSpotPriceLimit"`
// The bidding method of the compute nodes. Default value: `NoSpot`. Valid values:
// - `NoSpot`: The compute nodes are pay-as-you-go instances.
// - `SpotWithPriceLimit`: The compute nodes are preemptible instances that have a user-defined maximum hourly price.
// - `SpotAsPriceGo`: The compute nodes are preemptible instances for which the market price at the time of purchase is used as the bid price.
ComputeSpotStrategy *string `pulumi:"computeSpotStrategy"`
// The mode in which the cluster is deployed. Valid values: `Standard`, `Simple`, `Tiny`. Default value: Standard.
// - `Standard`: An account node, a scheduling node, a logon node, and multiple compute nodes are separately deployed.
// - `Simple`: A management node, a logon node, and multiple compute nodes are deployed. The management node consists of an account node and a scheduling node. The logon node and compute nodes are separately deployed.
// - `Tiny`: A management node and multiple compute nodes are deployed. The management node consists of an account node, a scheduling node, and a logon node. The compute nodes are separately deployed.
DeployMode *string `pulumi:"deployMode"`
// The description of the cluster. The description must be `2` to `256` characters in length. It cannot start with `http://` or `https://`.
Description *string `pulumi:"description"`
// The domain name of the on-premises cluster. This parameter takes effect only when the AccoutType parameter is set to Idap.
Domain *string `pulumi:"domain"`
// The billing method of the nodes.
EcsChargeType *string `pulumi:"ecsChargeType"`
// The version of E-HPC. By default, the parameter is set to the latest version number.
EhpcVersion *string `pulumi:"ehpcVersion"`
// Specifies whether to enable the high availability feature. Default value: `false`. **Note:** If high availability is enabled, a primary management node and a secondary management node are used.
HaEnable *bool `pulumi:"haEnable"`
// The ID of the image.
ImageId *string `pulumi:"imageId"`
// The type of the image. Valid values: `others`, `self`, `system`, `marketplace`. Default value: `system`.
ImageOwnerAlias *string `pulumi:"imageOwnerAlias"`
// The URL of the job files that are uploaded to an Object Storage Service (OSS) bucket.
InputFileUrl *string `pulumi:"inputFileUrl"`
// Specifies whether to enable auto scaling. Default value: `false`.
IsComputeEss *bool `pulumi:"isComputeEss"`
// The queue of the nodes to which the additional file system is attached.
JobQueue *string `pulumi:"jobQueue"`
// The name of the AccessKey pair.
KeyPairName *string `pulumi:"keyPairName"`
// The number of the logon nodes. Valid values: `1`.
LoginCount int `pulumi:"loginCount"`
// The instance type of the logon nodes.
LoginInstanceType string `pulumi:"loginInstanceType"`
// The number of the management nodes. Valid values: 1 and 2.
ManagerCount *int `pulumi:"managerCount"`
// The instance type of the management nodes.
ManagerInstanceType string `pulumi:"managerInstanceType"`
// The image tag of the operating system.
OsTag string `pulumi:"osTag"`
// The root password of the logon node. The password must be 8 to 30 characters in length and contain at least three of the following items: uppercase letters, lowercase letters, digits, and special characters. The password can contain the following special characters: `( ) ~ ! @ # $ % ^ & * - + = { } [ ] : ; ‘ < > , . ? /`. You must specify either `password` or `keyPairName`. If both are specified, the Password parameter prevails.
Password *string `pulumi:"password"`
// The duration of the subscription. The unit of the duration is specified by the `periodUnit` parameter. Default value: `1`.
// * If you set PriceUnit to Year, the valid values of the Period parameter are 1, 2, and 3.
// * If you set PriceUnit to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
// * If you set PriceUnit to Hour, the valid value of the Period parameter is 1.
Period *int `pulumi:"period"`
// The unit of the subscription duration. Valid values: `Year`, `Month`, `Hour`. Default value: `Month`.
PeriodUnit *string `pulumi:"periodUnit"`
// The mode configurations of the plug-in. This parameter takes effect only when the SchedulerType parameter is set to custom. The value must be a JSON string. The parameter contains the following parameters: pluginMod, pluginLocalPath, and pluginOssPath.
// - pluginMod: the mode of the plug-in. The following modes are supported:
// - oss: The plug-in is downloaded and decompressed from OSS to a local path. The local path is specified by the pluginLocalPath parameter.
// - image: By default, the plug-in is stored in a pre-defined local path. The local path is specified by the pluginLocalPath parameter.
// - pluginLocalPath: the local path where the plug-in is stored. We recommend that you select a shared directory in oss mode and a non-shared directory in image mode.
// - pluginOssPath: the remote path where the plug-in is stored in OSS. This parameter takes effect only when the pluginMod parameter is set to oss.
Plugin *string `pulumi:"plugin"`
// The post install script. See the following `Block postInstallScript`.
PostInstallScripts []ClusterPostInstallScript `pulumi:"postInstallScripts"`
// The node of the RAM role.
RamNodeTypes []string `pulumi:"ramNodeTypes"`
// The name of the Resource Access Management (RAM) role.
RamRoleName *string `pulumi:"ramRoleName"`
// The release instance. Valid values: `true`.
ReleaseInstance *bool `pulumi:"releaseInstance"`
// The remote directory to which the additional file system is mounted.
RemoteDirectory *string `pulumi:"remoteDirectory"`
// Specifies whether to enable Virtual Network Computing (VNC). Default value: `false`.
RemoteVisEnable *bool `pulumi:"remoteVisEnable"`
// The ID of the resource group.
ResourceGroupId *string `pulumi:"resourceGroupId"`
// The ID of the Super Computing Cluster (SCC) instance. If you specify the parameter, the SCC instance is moved to a new SCC cluster.
SccClusterId *string `pulumi:"sccClusterId"`
// The type of the scheduler. Valid values: `pbs`, `slurm`, `opengridscheduler` and `deadline`. Default value: `pbs`.
SchedulerType *string `pulumi:"schedulerType"`
// The ID of the security group to which the cluster belongs.
SecurityGroupId *string `pulumi:"securityGroupId"`
// If you do not use an existing security group, set the parameter to the name of a new security group. A default policy is applied to the new security group.
SecurityGroupName *string `pulumi:"securityGroupName"`
// The performance level of the ESSD that is used as the system disk. Default value: `PL1` For more information, see [ESSDs](https://www.alibabacloud.com/help/en/elastic-compute-service/latest/essds). Valid values:
// * `PL0`: A single ESSD can deliver up to 10,000 random read/write IOPS.
// * `PL1`: A single ESSD can deliver up to 50,000 random read/write IOPS.
// * `PL2`: A single ESSD can deliver up to 100,000 random read/write IOPS.
// * `PL3`: A single ESSD can deliver up to 1,000,000 random read/write IOPS.
SystemDiskLevel *string `pulumi:"systemDiskLevel"`
// The size of the system disk. Unit: `GB`. Valid values: `40` to `500`. Default value: `40`.
SystemDiskSize *int `pulumi:"systemDiskSize"`
// The type of the system disk. Valid values: `cloudEfficiency`, `cloudSsd`, `cloudEssd` or `cloud`. Default value: `cloudSsd`.
SystemDiskType *string `pulumi:"systemDiskType"`
// The ID of the additional file system.
VolumeId *string `pulumi:"volumeId"`
// The mount options of the file system.
VolumeMountOption *string `pulumi:"volumeMountOption"`
// The mount target of the additional file system.
VolumeMountpoint *string `pulumi:"volumeMountpoint"`
// The type of the protocol that is used by the additional file system. Valid values: `NFS`, `SMB`. Default value: `NFS`
VolumeProtocol *string `pulumi:"volumeProtocol"`
// The type of the additional shared storage. Only NAS file systems are supported.
VolumeType *string `pulumi:"volumeType"`
// The ID of the virtual private cloud (VPC) to which the cluster belongs.
VpcId *string `pulumi:"vpcId"`
// The ID of the vSwitch. E-HPC supports only VPC networks.
VswitchId *string `pulumi:"vswitchId"`
// Specifies whether not to install the agent. Default value: `false`.
WithoutAgent *bool `pulumi:"withoutAgent"`
// Specifies whether the logon node uses an elastic IP address (EIP). Default value: `false`.
WithoutElasticIp *bool `pulumi:"withoutElasticIp"`
// The ID of the zone.
ZoneId *string `pulumi:"zoneId"`
}
// The set of arguments for constructing a Cluster resource.
type ClusterArgs struct {
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
AccountType pulumi.StringPtrInput
// The additional volumes. See the following `Block additionalVolumes`.
AdditionalVolumes ClusterAdditionalVolumeArrayInput
// The application. See the following `Block application`.
Applications ClusterApplicationArrayInput
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
AutoRenew pulumi.BoolPtrInput
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
AutoRenewPeriod pulumi.IntPtrInput
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
ClientVersion pulumi.StringPtrInput
// The name of the cluster. The name must be `2` to `64` characters in length.
ClusterName pulumi.StringInput
// The version of the cluster. Default value: `1.0`.
ClusterVersion pulumi.StringPtrInput
// The number of the compute nodes. Valid values: `1` to `99`.
ComputeCount pulumi.IntInput
// Specifies whether the compute nodes support hyper-threading. Default value: `true`.
ComputeEnableHt pulumi.BoolPtrInput
// The instance type of the compute nodes.
ComputeInstanceType pulumi.StringInput
// The maximum hourly price of the compute nodes. A maximum of three decimal places can be used in the value of the parameter. The parameter is valid only when the ComputeSpotStrategy parameter is set to SpotWithPriceLimit.
ComputeSpotPriceLimit pulumi.StringPtrInput
// The bidding method of the compute nodes. Default value: `NoSpot`. Valid values:
// - `NoSpot`: The compute nodes are pay-as-you-go instances.
// - `SpotWithPriceLimit`: The compute nodes are preemptible instances that have a user-defined maximum hourly price.
// - `SpotAsPriceGo`: The compute nodes are preemptible instances for which the market price at the time of purchase is used as the bid price.
ComputeSpotStrategy pulumi.StringPtrInput
// The mode in which the cluster is deployed. Valid values: `Standard`, `Simple`, `Tiny`. Default value: Standard.
// - `Standard`: An account node, a scheduling node, a logon node, and multiple compute nodes are separately deployed.
// - `Simple`: A management node, a logon node, and multiple compute nodes are deployed. The management node consists of an account node and a scheduling node. The logon node and compute nodes are separately deployed.
// - `Tiny`: A management node and multiple compute nodes are deployed. The management node consists of an account node, a scheduling node, and a logon node. The compute nodes are separately deployed.
DeployMode pulumi.StringPtrInput
// The description of the cluster. The description must be `2` to `256` characters in length. It cannot start with `http://` or `https://`.
Description pulumi.StringPtrInput
// The domain name of the on-premises cluster. This parameter takes effect only when the AccoutType parameter is set to Idap.
Domain pulumi.StringPtrInput
// The billing method of the nodes.
EcsChargeType pulumi.StringPtrInput
// The version of E-HPC. By default, the parameter is set to the latest version number.
EhpcVersion pulumi.StringPtrInput
// Specifies whether to enable the high availability feature. Default value: `false`. **Note:** If high availability is enabled, a primary management node and a secondary management node are used.
HaEnable pulumi.BoolPtrInput
// The ID of the image.
ImageId pulumi.StringPtrInput
// The type of the image. Valid values: `others`, `self`, `system`, `marketplace`. Default value: `system`.
ImageOwnerAlias pulumi.StringPtrInput
// The URL of the job files that are uploaded to an Object Storage Service (OSS) bucket.
InputFileUrl pulumi.StringPtrInput
// Specifies whether to enable auto scaling. Default value: `false`.
IsComputeEss pulumi.BoolPtrInput
// The queue of the nodes to which the additional file system is attached.
JobQueue pulumi.StringPtrInput
// The name of the AccessKey pair.
KeyPairName pulumi.StringPtrInput
// The number of the logon nodes. Valid values: `1`.
LoginCount pulumi.IntInput
// The instance type of the logon nodes.
LoginInstanceType pulumi.StringInput
// The number of the management nodes. Valid values: 1 and 2.
ManagerCount pulumi.IntPtrInput
// The instance type of the management nodes.
ManagerInstanceType pulumi.StringInput
// The image tag of the operating system.
OsTag pulumi.StringInput
// The root password of the logon node. The password must be 8 to 30 characters in length and contain at least three of the following items: uppercase letters, lowercase letters, digits, and special characters. The password can contain the following special characters: `( ) ~ ! @ # $ % ^ & * - + = { } [ ] : ; ‘ < > , . ? /`. You must specify either `password` or `keyPairName`. If both are specified, the Password parameter prevails.
Password pulumi.StringPtrInput
// The duration of the subscription. The unit of the duration is specified by the `periodUnit` parameter. Default value: `1`.
// * If you set PriceUnit to Year, the valid values of the Period parameter are 1, 2, and 3.
// * If you set PriceUnit to Month, the valid values of the Period parameter are 1, 2, 3, 4, 5, 6, 7, 8, and 9.
// * If you set PriceUnit to Hour, the valid value of the Period parameter is 1.
Period pulumi.IntPtrInput
// The unit of the subscription duration. Valid values: `Year`, `Month`, `Hour`. Default value: `Month`.
PeriodUnit pulumi.StringPtrInput
// The mode configurations of the plug-in. This parameter takes effect only when the SchedulerType parameter is set to custom. The value must be a JSON string. The parameter contains the following parameters: pluginMod, pluginLocalPath, and pluginOssPath.
// - pluginMod: the mode of the plug-in. The following modes are supported:
// - oss: The plug-in is downloaded and decompressed from OSS to a local path. The local path is specified by the pluginLocalPath parameter.
// - image: By default, the plug-in is stored in a pre-defined local path. The local path is specified by the pluginLocalPath parameter.
// - pluginLocalPath: the local path where the plug-in is stored. We recommend that you select a shared directory in oss mode and a non-shared directory in image mode.
// - pluginOssPath: the remote path where the plug-in is stored in OSS. This parameter takes effect only when the pluginMod parameter is set to oss.
Plugin pulumi.StringPtrInput
// The post install script. See the following `Block postInstallScript`.
PostInstallScripts ClusterPostInstallScriptArrayInput
// The node of the RAM role.
RamNodeTypes pulumi.StringArrayInput
// The name of the Resource Access Management (RAM) role.
RamRoleName pulumi.StringPtrInput
// The release instance. Valid values: `true`.
ReleaseInstance pulumi.BoolPtrInput
// The remote directory to which the additional file system is mounted.
RemoteDirectory pulumi.StringPtrInput
// Specifies whether to enable Virtual Network Computing (VNC). Default value: `false`.
RemoteVisEnable pulumi.BoolPtrInput
// The ID of the resource group.
ResourceGroupId pulumi.StringPtrInput
// The ID of the Super Computing Cluster (SCC) instance. If you specify the parameter, the SCC instance is moved to a new SCC cluster.
SccClusterId pulumi.StringPtrInput
// The type of the scheduler. Valid values: `pbs`, `slurm`, `opengridscheduler` and `deadline`. Default value: `pbs`.
SchedulerType pulumi.StringPtrInput
// The ID of the security group to which the cluster belongs.
SecurityGroupId pulumi.StringPtrInput
// If you do not use an existing security group, set the parameter to the name of a new security group. A default policy is applied to the new security group.
SecurityGroupName pulumi.StringPtrInput
// The performance level of the ESSD that is used as the system disk. Default value: `PL1` For more information, see [ESSDs](https://www.alibabacloud.com/help/en/elastic-compute-service/latest/essds). Valid values:
// * `PL0`: A single ESSD can deliver up to 10,000 random read/write IOPS.
// * `PL1`: A single ESSD can deliver up to 50,000 random read/write IOPS.
// * `PL2`: A single ESSD can deliver up to 100,000 random read/write IOPS.
// * `PL3`: A single ESSD can deliver up to 1,000,000 random read/write IOPS.
SystemDiskLevel pulumi.StringPtrInput
// The size of the system disk. Unit: `GB`. Valid values: `40` to `500`. Default value: `40`.
SystemDiskSize pulumi.IntPtrInput
// The type of the system disk. Valid values: `cloudEfficiency`, `cloudSsd`, `cloudEssd` or `cloud`. Default value: `cloudSsd`.
SystemDiskType pulumi.StringPtrInput
// The ID of the additional file system.
VolumeId pulumi.StringPtrInput
// The mount options of the file system.
VolumeMountOption pulumi.StringPtrInput
// The mount target of the additional file system.
VolumeMountpoint pulumi.StringPtrInput
// The type of the protocol that is used by the additional file system. Valid values: `NFS`, `SMB`. Default value: `NFS`
VolumeProtocol pulumi.StringPtrInput
// The type of the additional shared storage. Only NAS file systems are supported.
VolumeType pulumi.StringPtrInput
// The ID of the virtual private cloud (VPC) to which the cluster belongs.
VpcId pulumi.StringPtrInput
// The ID of the vSwitch. E-HPC supports only VPC networks.
VswitchId pulumi.StringPtrInput
// Specifies whether not to install the agent. Default value: `false`.
WithoutAgent pulumi.BoolPtrInput
// Specifies whether the logon node uses an elastic IP address (EIP). Default value: `false`.
WithoutElasticIp pulumi.BoolPtrInput
// The ID of the zone.
ZoneId pulumi.StringPtrInput
}
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
}
// The type of the domain account service. Valid values: `nis`, `ldap`. Default value: `nis`
func (o ClusterOutput) AccountType() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.AccountType }).(pulumi.StringOutput)
}
// The additional volumes. See the following `Block additionalVolumes`.
func (o ClusterOutput) AdditionalVolumes() ClusterAdditionalVolumeArrayOutput {
return o.ApplyT(func(v *Cluster) ClusterAdditionalVolumeArrayOutput { return v.AdditionalVolumes }).(ClusterAdditionalVolumeArrayOutput)
}
// The application. See the following `Block application`.
func (o ClusterOutput) Applications() ClusterApplicationArrayOutput {
return o.ApplyT(func(v *Cluster) ClusterApplicationArrayOutput { return v.Applications }).(ClusterApplicationArrayOutput)
}
// Specifies whether to enable auto-renewal for the subscription. Default value: `false`.
func (o ClusterOutput) AutoRenew() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.BoolPtrOutput { return v.AutoRenew }).(pulumi.BoolPtrOutput)
}
// The auto-renewal period of the subscription compute nodes. The parameter takes effect when AutoRenew is set to true.
func (o ClusterOutput) AutoRenewPeriod() pulumi.IntPtrOutput {
return o.ApplyT(func(v *Cluster) pulumi.IntPtrOutput { return v.AutoRenewPeriod }).(pulumi.IntPtrOutput)
}
// The version of the E-HPC client. By default, the parameter is set to the latest version number.
func (o ClusterOutput) ClientVersion() pulumi.StringOutput {
return o.ApplyT(func(v *Cluster) pulumi.StringOutput { return v.ClientVersion }).(pulumi.StringOutput)
}