CfnClusterProps
Struct External
Properties for defining a CfnCluster.
| Source | |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_pcs as pcs } from 'aws-cdk-lib';
const cfnClusterProps: pcs.CfnClusterProps = {
networking: {
networkType: 'networkType',
securityGroupIds: ['securityGroupIds'],
subnetIds: ['subnetIds'],
},
scheduler: {
type: 'type',
version: 'version',
},
size: 'size',
// the properties below are optional
name: 'name',
slurmConfiguration: {
accounting: {
mode: 'mode',
// the properties below are optional
defaultPurgeTimeInDays: 123,
},
authKey: {
secretArn: 'secretArn',
secretVersion: 'secretVersion',
},
cgroupCustomSettings: [{
parameterName: 'parameterName',
parameterValue: 'parameterValue',
}],
jwtAuth: {
jwtKey: {
secretArn: 'secretArn',
secretVersion: 'secretVersion',
},
},
scaleDownIdleTimeInSeconds: 123,
slurmCustomSettings: [{
parameterName: 'parameterName',
parameterValue: 'parameterValue',
}],
slurmdbdCustomSettings: [{
parameterName: 'parameterName',
parameterValue: 'parameterValue',
}],
slurmRest: {
mode: 'mode',
},
},
tags: {
tagsKey: 'tags',
},
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_pcs as pcs
cfn_cluster_props = pcs.CfnClusterProps(
networking=pcs.CfnCluster.NetworkingProperty(
network_type="networkType",
security_group_ids=["securityGroupIds"],
subnet_ids=["subnetIds"]
),
scheduler=pcs.CfnCluster.SchedulerProperty(
type="type",
version="version"
),
size="size",
# the properties below are optional
name="name",
slurm_configuration=pcs.CfnCluster.SlurmConfigurationProperty(
accounting=pcs.CfnCluster.AccountingProperty(
mode="mode",
# the properties below are optional
default_purge_time_in_days=123
),
auth_key=pcs.CfnCluster.AuthKeyProperty(
secret_arn="secretArn",
secret_version="secretVersion"
),
cgroup_custom_settings=[pcs.CfnCluster.CgroupCustomSettingProperty(
parameter_name="parameterName",
parameter_value="parameterValue"
)],
jwt_auth=pcs.CfnCluster.JwtAuthProperty(
jwt_key=pcs.CfnCluster.JwtKeyProperty(
secret_arn="secretArn",
secret_version="secretVersion"
)
),
scale_down_idle_time_in_seconds=123,
slurm_custom_settings=[pcs.CfnCluster.SlurmCustomSettingProperty(
parameter_name="parameterName",
parameter_value="parameterValue"
)],
slurmdbd_custom_settings=[pcs.CfnCluster.SlurmdbdCustomSettingProperty(
parameter_name="parameterName",
parameter_value="parameterValue"
)],
slurm_rest=pcs.CfnCluster.SlurmRestProperty(
mode="mode"
)
),
tags={
"tags_key": "tags"
}
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.pcs.*;
CfnClusterProps cfnClusterProps = CfnClusterProps.builder()
.networking(NetworkingProperty.builder()
.networkType("networkType")
.securityGroupIds(List.of("securityGroupIds"))
.subnetIds(List.of("subnetIds"))
.build())
.scheduler(SchedulerProperty.builder()
.type("type")
.version("version")
.build())
.size("size")
// the properties below are optional
.name("name")
.slurmConfiguration(SlurmConfigurationProperty.builder()
.accounting(AccountingProperty.builder()
.mode("mode")
// the properties below are optional
.defaultPurgeTimeInDays(123)
.build())
.authKey(AuthKeyProperty.builder()
.secretArn("secretArn")
.secretVersion("secretVersion")
.build())
.cgroupCustomSettings(List.of(CgroupCustomSettingProperty.builder()
.parameterName("parameterName")
.parameterValue("parameterValue")
.build()))
.jwtAuth(JwtAuthProperty.builder()
.jwtKey(JwtKeyProperty.builder()
.secretArn("secretArn")
.secretVersion("secretVersion")
.build())
.build())
.scaleDownIdleTimeInSeconds(123)
.slurmCustomSettings(List.of(SlurmCustomSettingProperty.builder()
.parameterName("parameterName")
.parameterValue("parameterValue")
.build()))
.slurmdbdCustomSettings(List.of(SlurmdbdCustomSettingProperty.builder()
.parameterName("parameterName")
.parameterValue("parameterValue")
.build()))
.slurmRest(SlurmRestProperty.builder()
.mode("mode")
.build())
.build())
.tags(Map.of(
"tagsKey", "tags"))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.PCS;
var cfnClusterProps = new CfnClusterProps {
Networking = new NetworkingProperty {
NetworkType = "networkType",
SecurityGroupIds = new [] { "securityGroupIds" },
SubnetIds = new [] { "subnetIds" }
},
Scheduler = new SchedulerProperty {
Type = "type",
Version = "version"
},
Size = "size",
// the properties below are optional
Name = "name",
SlurmConfiguration = new SlurmConfigurationProperty {
Accounting = new AccountingProperty {
Mode = "mode",
// the properties below are optional
DefaultPurgeTimeInDays = 123
},
AuthKey = new AuthKeyProperty {
SecretArn = "secretArn",
SecretVersion = "secretVersion"
},
CgroupCustomSettings = new [] { new CgroupCustomSettingProperty {
ParameterName = "parameterName",
ParameterValue = "parameterValue"
} },
JwtAuth = new JwtAuthProperty {
JwtKey = new JwtKeyProperty {
SecretArn = "secretArn",
SecretVersion = "secretVersion"
}
},
ScaleDownIdleTimeInSeconds = 123,
SlurmCustomSettings = new [] { new SlurmCustomSettingProperty {
ParameterName = "parameterName",
ParameterValue = "parameterValue"
} },
SlurmdbdCustomSettings = new [] { new SlurmdbdCustomSettingProperty {
ParameterName = "parameterName",
ParameterValue = "parameterValue"
} },
SlurmRest = new SlurmRestProperty {
Mode = "mode"
}
},
Tags = new Dictionary<string, string> {
{ "tagsKey", "tags" }
}
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
cfnClusterProps := &CfnClusterProps{
Networking: &NetworkingProperty{
NetworkType: jsii.String("networkType"),
SecurityGroupIds: []*string{
jsii.String("securityGroupIds"),
},
SubnetIds: []*string{
jsii.String("subnetIds"),
},
},
Scheduler: &SchedulerProperty{
Type: jsii.String("type"),
Version: jsii.String("version"),
},
Size: jsii.String("size"),
// the properties below are optional
Name: jsii.String("name"),
SlurmConfiguration: &SlurmConfigurationProperty{
Accounting: &AccountingProperty{
Mode: jsii.String("mode"),
// the properties below are optional
DefaultPurgeTimeInDays: jsii.Number(123),
},
AuthKey: &AuthKeyProperty{
SecretArn: jsii.String("secretArn"),
SecretVersion: jsii.String("secretVersion"),
},
CgroupCustomSettings: []interface{}{
&CgroupCustomSettingProperty{
ParameterName: jsii.String("parameterName"),
ParameterValue: jsii.String("parameterValue"),
},
},
JwtAuth: &JwtAuthProperty{
JwtKey: &JwtKeyProperty{
SecretArn: jsii.String("secretArn"),
SecretVersion: jsii.String("secretVersion"),
},
},
ScaleDownIdleTimeInSeconds: jsii.Number(123),
SlurmCustomSettings: []interface{}{
&SlurmCustomSettingProperty{
ParameterName: jsii.String("parameterName"),
ParameterValue: jsii.String("parameterValue"),
},
},
SlurmdbdCustomSettings: []interface{}{
&SlurmdbdCustomSettingProperty{
ParameterName: jsii.String("parameterName"),
ParameterValue: jsii.String("parameterValue"),
},
},
SlurmRest: &SlurmRestProperty{
Mode: jsii.String("mode"),
},
},
Tags: map[string]*string{
"tagsKey": jsii.String("tags"),
},
}
Properties
The name that identifies the cluster.
networkingIResolvable | CfnCluster.NetworkingPropertynetworkingtyping.Union[IResolvable, NetworkingProperty]networkingIResolvableNetworkingIResolvableNetworkinginterface{} required #The networking configuration for the cluster's control plane.
schedulerIResolvable | CfnCluster.SchedulerPropertyschedulertyping.Union[IResolvable, SchedulerProperty]schedulerIResolvableSchedulerIResolvableSchedulerinterface{} required #The cluster management and job scheduling software associated with the cluster.
The size of the cluster.
SMALL: 32 compute nodes and 256 jobsMEDIUM: 512 compute nodes and 8192 jobsLARGE: 2048 compute nodes and 16,384 jobs
slurmConfigurationoptionalIResolvable | CfnCluster.slurm_configurationoptionaltyping.Union[IResolvable, SlurmConfigurationProperty]slurmConfigurationoptionalIResolvableSlurmConfigurationoptionalIResolvableSlurmConfigurationoptionalinterface{} #Additional options related to the Slurm scheduler.
tagsoptional{ [key: string]: string }tagsoptionaltyping.Mapping[str, str]tagsoptionalMap<String, String>TagsoptionalIDictionary<string, string>Tagsoptional*map[string]*string #1 or more tags added to the resource.
Each tag consists of a tag key and tag value. The tag value is optional and can be an empty string.