Bug 1697869 - ansible should own /usr/share/ansible and subdirectories, /usr/share/ansible/roles
Summary: ansible should own /usr/share/ansible and subdirectories, /usr/share/ansible/...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: ansible
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Kevin Fenzi
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-09 08:31 UTC by Till Maas
Modified: 2019-07-30 01:45 UTC (History)
6 users (show)

Fixed In Version: ansible-2.8.2-1.el7 ansible-2.8.2-1.fc30 ansible-2.8.2-1.fc29
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-07-23 01:49:12 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Potential change to own all defaults system paths in ansible config (1.44 KB, patch)
2019-04-16 03:57 UTC, Toshio Kuratomi
no flags Details | Diff

Description Till Maas 2019-04-09 08:31:23 UTC
Description of problem:
ansible should own 
/usr/share/ansible
/usr/share/ansible/roles
/usr/share/ansible/inventory

and maybe oher directories that ansible accepts for extension

Version-Release number of selected component (if applicable):
ansible-2.7.9-1.fc28

linux-system-roles and standard-test-roles add content to the mentioned directories to enhance Ansible. To ensure the directories are properly owned ansible should IMHO own them.

Comment 1 Pavel Cahyna 2019-04-09 08:35:47 UTC
My RHEL package (when Ansible was still in RHEL 7 Extras) used to have this in %files:
%dir /usr/share/ansible
%dir /usr/share/ansible/roles
%dir /usr/share/ansible/plugins

Comment 2 Pavel Cahyna 2019-04-09 08:39:14 UTC
As do the Ansible Engine builds (I looked at ansible-2.7.9-1.el7ae)

Comment 3 Kevin Fenzi 2019-04-12 19:10:23 UTC
PR applied. Do you need it now? Or can we wait for the next release? Or would you like rawhide now?

Comment 4 Toshio Kuratomi 2019-04-12 20:43:41 UTC
Hold on.... what's the rationale for owning those directories?  The Ansible Engine 2.8.0 build was going to drop those directories from the spec file as we don't place any files in there and to be more inline with the Fedora package.  If they're going to be added to the Fedora package, I should probably re-add them to the engine package as well.  It would be good if we had a common understanding of the criteria for adding the directories, though.

Perhaps something like "every /usr/share/ansible directory listed in  https://github.com/ansible/ansible/blob/devel/lib/ansible/config/base.yml " ?

Comment 5 Till Maas 2019-04-15 09:15:26 UTC
Toshio, the current need comes from the linux-system-roles package that puts content there. For RHEL there is rhel-system-roles with the same problem. To ensure proper directory ownership the ansible package should own the directories.

Kevin, thank you! The next release is fine with me. I do not think it rewards a separate update.

Comment 6 Toshio Kuratomi 2019-04-15 20:49:00 UTC
Okay, but what I'm saying is that we need to coordinate this change otherwise linux-system-roles won't work with the packages provided by Ansible Engine 2.8.  Can we agree on what criteria to use to decide what directories need to be owned by the packages?

Comment 7 Toshio Kuratomi 2019-04-16 03:57:35 UTC
Created attachment 1555378 [details]
Potential change to own all defaults system paths in ansible config

Okay, this would implement owning all of the system paths that ansible lists in its base config.

Comment 8 Till Maas 2019-04-16 07:26:10 UTC
Yes, it makes sense to add all directories to the spec where other RPMs could drop files/directories. Unfortunately your patch seems to be wrong:

It creates everything below %{_datadir}/ansible/plugins/ but the roles directory needs to be created in %{_datadir}/ansible/

https://github.com/ansible/ansible/blob/devel/lib/ansible/config/base.yml#L989
https://github.com/ansible/ansible/blob/devel/lib/ansible/config/base.yml#L380

Also it would be nice to sort the plugin type entries to make it easier to check if a certain entry is in there.

Comment 9 Toshio Kuratomi 2019-04-16 17:35:39 UTC
<nod> Yeah, and it looks like the same fix is needed for collections as well.

I'm not sure what the best sort order is.  The current order matches what's in the base.yml file which makes a simple grep work well but doesn't work so well when upstream changes the order in their file.

Comment 10 Toshio Kuratomi 2019-04-16 17:48:03 UTC
Till, PR here: https://src.fedoraproject.org/rpms/ansible/pull-request/9

Comment 11 Miro Hrončok 2019-04-26 08:06:38 UTC
Can this be fixed in Fedora 30 as well please?

Comment 12 Fedora Update System 2019-07-21 15:41:58 UTC
FEDORA-2019-7301f6afd1 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-7301f6afd1

Comment 13 Fedora Update System 2019-07-21 15:43:42 UTC
FEDORA-2019-4523b5e0c2 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-4523b5e0c2

Comment 14 Fedora Update System 2019-07-21 15:45:22 UTC
FEDORA-EPEL-2019-e96deab9a3 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-e96deab9a3

Comment 15 Fedora Update System 2019-07-22 01:10:37 UTC
ansible-2.8.2-1.fc30, python-sphinx-notfound-page-0.4-2.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-7301f6afd1

Comment 16 Fedora Update System 2019-07-22 01:58:54 UTC
ansible-2.8.2-1.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-e96deab9a3

Comment 17 Fedora Update System 2019-07-22 08:11:48 UTC
ansible-2.8.2-1.fc29, python-sphinx-notfound-page-0.4-2.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-4523b5e0c2

Comment 18 Fedora Update System 2019-07-23 01:49:12 UTC
ansible-2.8.2-1.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 19 Fedora Update System 2019-07-26 01:00:22 UTC
ansible-2.8.2-1.fc30, python-sphinx-notfound-page-0.4-2.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2019-07-30 01:45:24 UTC
ansible-2.8.2-1.fc29, python-sphinx-notfound-page-0.4-2.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.