2013年10月22日

AWS EC2 user-data launch script for ec2 instances

Specify a start-up script when you launch an EC2 instance.
Launch instance.

ec2-run-instances ami-c96bf3c8 -k capy-aws -t t1.micro -g capy-ec2 --user-data-file launch-staging.sh

Auto scale
as-create-launch-config staging-lc --image-id ami-7b4cd77a --instance-type t1.micro --user-data-file launch-staging.sh