Create CloudFormation stack with EC2 Keypair by terraform
When you use terraform, you can use aws_key_pair” to import your own keypair into AWS. Example template https: […]
広告ここから
広告ここまで
目次
When you use terraform, you can use aws_key_pair"
to import your own keypair into AWS.
Example template
https://gist.github.com/hideokamoto/cce590a1a4143456f05c201527bb71a3
How to run
Just run $ terraform apply
.
Tips
Import your local CloudFormation template into terraform
If you want to import your local CloudFormation templates,you can do this by using file(path) function.
resource "aws_cloudformation_stack" "network" { name = "Sample" parameters { KeyName = "${aws_key_pair.deployer.id}", SSHLocation = "0.0.0.0/0", } template_body = "${file("../single.yml")}" }