Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between Run-instances and create-instances in aws-cli?

I know run instances is to create the ec2-instance in aws-cli but what is create instances?? and also what is stack-id and layer-ids. I google it but didn't found any answer.

like image 830
Mukul Avatar asked Nov 15 '25 20:11

Mukul


1 Answers

You are looking at 2 AWS services here. In AWS CLI, run-instancesrefer to creating EC2 server.

create-instance is used in AWS OpsWorks, to create an instance in OpsWorks stack. In OpsWorks there are stacks and Layers. A stack is a collection of layers and layer represents a stack component, such as a load balancer or a set of application servers. stack-id refers to the Stack's ID to identify the desired OpsWorks stack and layer-id refers to a particular layer in the given stack.

I'll add the CLI documentation below since you didn't find it.

EC2 - https://docs.aws.amazon.com/cli/latest/reference/ec2/run-instances.html

OpsWorks - https://docs.aws.amazon.com/cli/latest/reference/opsworks/create-instance.html

like image 96
SAUJ Avatar answered Nov 17 '25 12:11

SAUJ



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!