I am looking at cloud trail logs , I could only see the instance id of the terminated instances. I have a requirement of fetching the ip(not instance id) that was assigned to a machine which has got terminated. I need this information for the machines those got terminated in last 1 hour. Is there a way I can get that by making API calls?
Using CloudTrail, I was able to search for ResourceName = i-0123abc and find the RunInstances event that had the ip in the event map under the following key tree:
responseElements.instancesSet.items[0].privateIpAddress
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With