Describe the bug
When creating a FargateComputeEnvironment using the construct and passing in compute_environment_name the resulting cloudformatation does not have the ComputeEnvironmentName property set.
Expected Behavior
ComputeEnvironmentName property set on the resulting AWS::Batch::ComputeEnvironment resource in the outputted CloudFormation.
Current Behavior
ComputeEnvironmentName property is not set on the resulting AWS::Batch::ComputeEnvironment resource in the outputted CloudFormation.
This only seems to affect the FargateComputeEnvironment construct and not others.
Reproduction Steps
# Resulting CloudFormation will not have ComputeEnvironmentName set
self.fargate_compute_env = batch.FargateComputeEnvironment(
self, 'FargateComputeEnv',
compute_environment_name='fargate',
enabled=True,
vpc=vpc,
)
# Resulting CloudFormation will have ComputeEnvironmentName set
self.gpu_compute_env = batch.ManagedEc2EcsComputeEnvironment(
self, 'GPUComputeEnv',
compute_environment_name='gpu',
enabled=True,
maxv_cpus=196,
vpc=vpc,
instance_types=[
ec2.InstanceType.of(ec2.InstanceClass.G5, ec2.InstanceSize.XLARGE2),
ec2.InstanceType.of(ec2.InstanceClass.G4DN, ec2.InstanceSize.XLARGE4)
],
)
Possible Solution
No response
Additional Information/Context
FargateComputeEnv155F00A9:
Type: AWS::Batch::ComputeEnvironment
Properties:
Type: managed
ComputeResources:
MaxvCpus: 256
SecurityGroupIds:
- Fn::GetAtt:
- FargateComputeEnvSecurityGroup914E8A54
- GroupId
Subnets:
- Ref: VpcIsolatedSubnet1SubnetE48C5737
- Ref: VpcIsolatedSubnet2Subnet16364B91
Type: FARGATE
UpdateToLatestImageVersion: true
ReplaceComputeEnvironment: false
State: ENABLED
UpdatePolicy: {}
Metadata:
aws:cdk:path: IdentificationTrainingInfra/FargateComputeEnv/Resource
.......
TrainingComputeEnvEDCE302F:
Type: AWS::Batch::ComputeEnvironment
Properties:
Type: managed
ComputeEnvironmentName:training-gpu
ComputeResources:
AllocationStrategy: BEST_FIT_PROGRESSIVE
InstanceRole:
Fn::GetAtt:
- TrainingComputeEnvInstanceProfile93AE79CA
- Arn
InstanceTypes:
- g5.2xlarge
- g4dn.4xlarge
- optimal
MaxvCpus: 196
MinvCpus: 0
SecurityGroupIds:
- Fn::GetAtt:
- TrainingComputeEnvSecurityGroup0C7AEB8B
- GroupId
Subnets:
- Ref: VpcIsolatedSubnet1SubnetE48C5737
- Ref: VpcIsolatedSubnet2Subnet16364B91
Type: EC2
UpdateToLatestImageVersion: true
ReplaceComputeEnvironment: false
State: ENABLED
UpdatePolicy: {}
Metadata:
aws:cdk:path: IdentificationTrainingInfra/TrainingComputeEnv/Resource
CDK CLI Version
2.81.0
Framework Version
No response
Node.js Version
19.8.1
OS
Mac OS 12
Language
Python
Language Version
3.11
Other information
No response
Describe the bug
When creating a
FargateComputeEnvironmentusing the construct and passing incompute_environment_namethe resulting cloudformatation does not have theComputeEnvironmentNameproperty set.Expected Behavior
ComputeEnvironmentNameproperty set on the resultingAWS::Batch::ComputeEnvironmentresource in the outputted CloudFormation.Current Behavior
ComputeEnvironmentNameproperty is not set on the resultingAWS::Batch::ComputeEnvironmentresource in the outputted CloudFormation.This only seems to affect the
FargateComputeEnvironmentconstruct and not others.Reproduction Steps
Possible Solution
No response
Additional Information/Context
CDK CLI Version
2.81.0
Framework Version
No response
Node.js Version
19.8.1
OS
Mac OS 12
Language
Python
Language Version
3.11
Other information
No response