I’m trying to streamline the EC2 startup process for third party clients.
What I need to do is have an elastic IP address associate with a WOWZA EC2 instance when I boot up. Is it possible to do this via user data?
If anyone has an example, it will be most useful. many thanks
I am looking for very something similar. I am using the EC2 API to try and script this and got half way there.
set JAVA_HOME=C:\Program Files\Java\jre6
set EC2_HOME=C:\path-to-ec2-API\ec2-api-tools-1.5.0.1-2011.11.30\
set EC2_PRIVATE_KEY=C:\PATH-TO-PRIVATE-EC2-CERT\PRIV.pem
set EC2_CERT=C:\PATHT-TO-PUBLIC-EC2-CERT\CERT.pem
ec2-run-instances ami-93824afa -g wowza
ec2-describe-instances
ec2-associate-address -i instanceID xx.xx.xx.xx
ec2-disassociate-address xx.xx.xx.xx
ec2-stop-instances instanceID
Looking for a clean way with a dos batch file to parse the ec2-describe-instances for the instance id to pass into the ec2-associate-address -i instanceID xx.xx.xx.xx
. If not i will have to use another language.