# Package Installation Without Dependencies

**URL:** <https://forum.ansible.com/t/package-installation-without-dependencies/28505>\
**Category:** Ansible Developer\
**Created:** [September 5, 2018, 2:32pm UTC](https://forum.ansible.com/t/package-installation-without-dependencies/28505 "2018-09-05T14:32:19Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![andrew.tauferner](https://avatars.discourse-cdn.com/v4/letter/a/c89c15/32.png) [@andrew.tauferner](https://forum.ansible.com/u/andrew.tauferner)\
**Post date:** [September 5, 2018, 2:32pm UTC](https://forum.ansible.com/t/package-installation-without-dependencies/28505/1 "2018-09-05T14:32:19Z")

</div>

I’m familiar with the zypper module and some other installers but none of them seem to give one complete control over package dependency requirements. The **disable\_recommends** argument is really just /usr/bin/zypper’s **–no-recommends** option which isn’t good enough because package requirements are still honored and automatically satisfied but installing dependent packages. Is there any installation module similar to zypper that allows the package installation to use something like rpm’s **–nodeps** option? Thanks.

---

<div class="post-metadata">

**Author:** ![andrew.tauferner](https://avatars.discourse-cdn.com/v4/letter/a/c89c15/32.png) [@andrew.tauferner](https://forum.ansible.com/u/andrew.tauferner)\
**Post date:** [September 5, 2018, 4:30pm UTC](https://forum.ansible.com/t/package-installation-without-dependencies/28505/2 "2018-09-05T16:30:09Z")

</div>

If the answer is ‘No. zypper and other package management modules do not give the caller complete control over package installation’ then I’d ask why. Would the community be opposed to extending something like the zypper module to include a **disable\_dependencies** argument?

---

<div class="post-metadata">

**Author:** ![Andrew\_Gaffney](https://avatars.discourse-cdn.com/v4/letter/a/71c47a/32.png) [@Andrew\_Gaffney](https://forum.ansible.com/u/Andrew_Gaffney)\
**Post date:** [September 5, 2018, 6:11pm UTC](https://forum.ansible.com/t/package-installation-without-dependencies/28505/3 "2018-09-05T18:11:20Z")

</div>

The ‘zypper’ module has ‘extra\_args’ and ‘extra\_args\_precommand’ params (since 2.4 and 2.6, respectively), which allow you to pass whatever arbitrary arguments that you want to zypper when installing a package.

[https://docs.ansible.com/ansible/latest/modules/zypper\_module.html#parameters](https://docs.ansible.com/ansible/latest/modules/zypper_module.html#parameters)

---

<div class="post-metadata">

**Author:** ![andrew.tauferner](https://avatars.discourse-cdn.com/v4/letter/a/c89c15/32.png) [@andrew.tauferner](https://forum.ansible.com/u/andrew.tauferner)\
**Post date:** [September 5, 2018, 6:45pm UTC](https://forum.ansible.com/t/package-installation-without-dependencies/28505/4 "2018-09-05T18:45:07Z")

</div>

Right but those are zypper command arguments. The zypper command itself (not the zypper module) has no way of ignoring package dependencies. At least no way that I know of. The zypper module could have used /usr/bin/zypper to download the specified RPMs and then used the rpm command to install them without dependencies. I have as much working in some local modifications to the zypper module.
