I am converting a Cloudformation template to terraform. I don't see materials online describing the terraform equivalent of CF structure.
Cloudformation
Resources:
CodeDeployApplication:
Type: 'AWS::CodeDeploy::Application'
Properties:
ApplicationName: !Join
- '-'
- - !Ref EnvName
- !Ref AppName
- Application
ComputePlatform: Lambda
I have converted as below. I am sure I have made a mistake in the 'name' part.Can you please help?
Terraform
resource "aws_codedeploy_app" "CodeDeployApplication" {
compute_platform = "Lambda"
name = "${var.EnvName}/${var.AppName}/Application"
}
The following CFN code:
ApplicationName: !Join
- '-'
- - !Ref EnvName
- !Ref AppName
- Application
will translate to:
name = "${var.EnvName}-${var.AppName}-Application"
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.