# file module to create a link to a file that does not exist

**URL:** <https://forum.ansible.com/t/file-module-to-create-a-link-to-a-file-that-does-not-exist/12582>\
**Category:** Ansible Project\
**Created:** [March 25, 2013, 10:28pm UTC](https://forum.ansible.com/t/file-module-to-create-a-link-to-a-file-that-does-not-exist/12582 "2013-03-25T22:28:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yves\_Dorfsman](https://avatars.discourse-cdn.com/v4/letter/y/9de0a6/32.png) [@Yves\_Dorfsman](https://forum.ansible.com/u/Yves_Dorfsman)\
**Post date:** [March 25, 2013, 10:28pm UTC](https://forum.ansible.com/t/file-module-to-create-a-link-to-a-file-that-does-not-exist/12582/1 "2013-03-25T22:28:06Z")

</div>

I thought I remembered seeing a thread about this, but I can't find it.

I am in a situation where I need to create a symlink to a file that does not exist yet, and the file module fails with "src file does not exist".

Any way around this?

Thanks.

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan2](https://avatars.discourse-cdn.com/v4/letter/m/da6949/32.png) [@Michael\_DeHaan2](https://forum.ansible.com/u/Michael_DeHaan2)\
**Post date:** [March 25, 2013, 11:11pm UTC](https://forum.ansible.com/t/file-module-to-create-a-link-to-a-file-that-does-not-exist/12582/2 "2013-03-25T23:11:11Z")

</div>

The shell module and just calling "ln" might be a good choice.
