rp346
rp346

Reputation: 7028

knife ec2 to vpc node

I am trying to launch node in EC2 VPC using chef knife ec2 server create to launch ec2 instance into VPC, But I looking a flag to specify vpc info.

Anyone know how to spin up ec2 instance into vpc using knife ec2 server create ?

Thanks

Upvotes: 0

Views: 65

Answers (1)

slayedbylucifer
slayedbylucifer

Reputation: 23502

There is a --subnet SUBNET_ID flag for knife ec2 command. You can specify which subnet of VPC you want the instance be created using this flag.

Refer: https://docs.chef.io/plugin_knife_ec2.html

You cannot provide VPC identity. However, you can provide subnet identity which eventually will create the instance in your VPC of choice.

Upvotes: 2

Related Questions