# Save remote property value to registered variable?

**URL:** <https://forum.ansible.com/t/save-remote-property-value-to-registered-variable/23037>\
**Category:** Ansible Project\
**Created:** [November 15, 2016, 10:01pm UTC](https://forum.ansible.com/t/save-remote-property-value-to-registered-variable/23037 "2016-11-15T22:01:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![burns498](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@burns498](https://forum.ansible.com/u/burns498)\
**Post date:** [November 15, 2016, 10:01pm UTC](https://forum.ansible.com/t/save-remote-property-value-to-registered-variable/23037/1 "2016-11-15T22:01:36Z")

</div>

Hello -

Is there a way to save a remote property value to a registered variable?

Example: Remote server has file stuff.properties with below sample content:

> var1=Hello  
> var2=World

Can Ansible reach out to that file, crack it open, find key “var2”, then register value “World”? I dont’ want the entire stuff.properties file, but just the value “World” from key “var2”.

In my head, I imagine there may be some way to setup a regex backrefrence to slurp out “World”. Or, perhaps first [fetch](http://docs.ansible.com/ansible/fetch_module.html), then [lookup](http://docs.ansible.com/ansible/playbooks_lookups.html), with a fancy [INI plugin](http://docs.ansible.com/ansible/playbooks_lookups.html#the-ini-file-lookup) logic?

Thanks
