Creating and configuring a virtual machine in Amazon EC2
Before creating and configuring a virtual machine in Amazon EC2, let's verify the existing nodes converged by Chef. Local virtual machines are only configured using Chef:
[root@devops1 Desktop]# knife node list tomcatserver
- After installing knife EC2 plugin, we can use
knife ec2 server create
command with following parameters to create new virtual machine:Parameter
Value
Description
-I
ami-1ecae776
ID of the Amazon machine image
-f
t2.micro
Type of virtual machine
-N
DevOpsVMonAWS
Name of the Chef node
--aws-access-key-id
Your access key ID
AWS account access key ID
--aws-secret-access-key
Your secret access key
AWS account secret access key
-S
Get DevOps for Web Development now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.