Two instances are running: batch-1sb4aih, a nightly job that talks to nobody outside, and api-1sb4aih, the market's API server.
-
List both, with their ids, states and addresses, in one table:
shaws ec2 describe-instances --query "Reservations[].Instances[].[InstanceId,State.Name,PrivateIpAddress,PublicIpAddress]" --output tableWhich row is which? Nothing in it says.
-
Show the same table for
api-1sb4aihalone, filtered by its Name tag. -
Save the API server's public IP, as text, to
~/ip.txt. -
Keep the API server's id in
ID, and tag it withEnv=prodand anOwnertag with your name.