# Magic with ansible modules

**URL:** <https://forum.ansible.com/t/magic-with-ansible-modules/13023>\
**Category:** Ansible Project\
**Created:** [June 26, 2013, 7:53pm UTC](https://forum.ansible.com/t/magic-with-ansible-modules/13023 "2013-06-26T19:53:40Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mario\_Adrian\_Lopez\_A](https://avatars.discourse-cdn.com/v4/letter/m/f14d63/32.png) [@Mario\_Adrian\_Lopez\_A](https://forum.ansible.com/u/Mario_Adrian_Lopez_A)\
**Post date:** [June 26, 2013, 7:53pm UTC](https://forum.ansible.com/t/magic-with-ansible-modules/13023/1 "2013-06-26T19:53:40Z")

</div>

Is there a way to include my own magic in an ansible module?

I’m writing some modules that can share code between them, so I was wondering if this was possible,  
Other idea that I had was just copying the code in the clients and then import it.

Anyone has tried something like this?

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan](https://avatars.discourse-cdn.com/v4/letter/m/c4cdca/32.png) [@Michael\_DeHaan](https://forum.ansible.com/u/Michael_DeHaan)\
**Post date:** [June 26, 2013, 9:35pm UTC](https://forum.ansible.com/t/magic-with-ansible-modules/13023/2 "2013-06-26T21:35:38Z")

</div>

Sure, basically you grind up some eye of newt, light some candles, and then bury a vintage Sparc mousepad at a crossroads at midnight, and…

Ok, yeah, no 🙂

The common module code is not user extensible.

–Michael

---

<div class="post-metadata">

**Author:** ![Mario\_Adrian\_Lopez\_A](https://avatars.discourse-cdn.com/v4/letter/m/f14d63/32.png) [@Mario\_Adrian\_Lopez\_A](https://forum.ansible.com/u/Mario_Adrian_Lopez_A)\
**Post date:** [June 27, 2013, 2:16pm UTC](https://forum.ansible.com/t/magic-with-ansible-modules/13023/3 "2013-06-27T14:16:06Z")

</div>

jajaja that was a good one.

Thanks Michael.
