# Refresh EC2 instance information after creation.

**URL:** <https://forum.ansible.com/t/refresh-ec2-instance-information-after-creation/17957>\
**Category:** Ansible Project\
**Tags:** aws\
**Created:** [April 11, 2015, 9:05am UTC](https://forum.ansible.com/t/refresh-ec2-instance-information-after-creation/17957 "2015-04-11T09:05:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nico\_K](https://avatars.discourse-cdn.com/v4/letter/n/46a35a/32.png) [@Nico\_K](https://forum.ansible.com/u/Nico_K)\
**Post date:** [April 11, 2015, 9:05am UTC](https://forum.ansible.com/t/refresh-ec2-instance-information-after-creation/17957/1 "2015-04-11T09:05:03Z")

</div>

Hi,

I’m creating an EC2 instance, then assigning an eIP to it, after I want to create a route53 entry using the eIP’s CNAME (eip task only returns ip\_address not the dns name sadly).

My current approach is to attempt to refresh the EC2 instance information (from the control host, I can’t login on the box yet; so no ec2\_facts), and from the refreshed information pull the public\_dns\_name.  
However I can’t find a simple way to refresh the instance information (other than aws ec2 describe-instances --filter … and then doing all kinds of magic to have ansible understand it’s output)…

Anyone who’s doing something similar or who could give me some pointers?

Thanks,  
Nico.
