Bug 1543510 - Add /usr/share/ansible/roles to default roles_path in ansible.cfg
Summary: Add /usr/share/ansible/roles to default roles_path in ansible.cfg
Keywords:
Status: CLOSED CURRENTRELEASE
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: 2018-02-08 15:35 UTC by Martin Perina
Modified: 2018-02-12 11:53 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-12 11:53:02 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Patch to change default roles_path to both directories (440 bytes, patch)
2018-02-08 15:37 UTC, Martin Perina
no flags Details | Diff

Description Martin Perina 2018-02-08 15:35:53 UTC
Description of problem:
​
On CentOS/RHEL ansible roles installed from RPM are by default stored in
'/usr/share/ansible/roles' directory. Due to this standard CentOS Extras
and RHEL ansible package contains by default in /etc/ansible/ansible.cfg
path to both directories:

  roles_path = /etc/ansible/roles:/usr/share/ansible/roles

Because ansible package will no longer be updated in CentOS Extras, we
would like to switch to ansible package from EPEL (instead of rebuilding
the package within CentOS Virt SIG), but without above change we cannot do
that.

And it also makes sense to use the same standard for Fedora, so ansible roles packagers will not need to make differences in spec files between Fedora and CentOS.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Martin Perina 2018-02-08 15:37:30 UTC
Created attachment 1393240 [details]
Patch to change default roles_path to both directories

Attached the patch we are using when rebuilding ansible package to provide default roles_path with both directories

Comment 2 Martin Perina 2018-02-08 15:40:25 UTC
Is it possible to backport this change also to current ansible-2.4.3 packages for FC27 and EPEL?

Comment 3 Pavel Cahyna 2018-02-08 15:42:40 UTC
Doesn't https://github.com/ansible/ansible/pull/23038 address your need already? I made the change to the default configuration file before that PR appeared in a released version, but now the PR should be included in a released version (2.4) already.

Comment 4 Pavel Cahyna 2018-02-08 15:45:35 UTC
That said, I think it it worth to make the default configuration file in the EPEL package identical to the one in the Extras package. This will save the users some work with merging the .rpmnew/.rpmsave files.

Comment 5 Martin Perina 2018-02-08 15:53:00 UTC
(In reply to Pavel Cahyna from comment #3)
> Doesn't https://github.com/ansible/ansible/pull/23038 address your need
> already? I made the change to the default configuration file before that PR
> appeared in a released version, but now the PR should be included in a
> released version (2.4) already.

Ha, I didn't know about this PR and I've created the bug after yesterday's email discussion with Kevin :-)

Ondro, could you please verify that already released 2.4.3 package [1] contains that change so we don't need to patch ansible.cfg?

[1] https://koji.fedoraproject.org/koji/buildinfo?buildID=1022839

Comment 6 Ondra Machacek 2018-02-12 11:01:39 UTC
(In reply to Martin Perina from comment #5)
> 
> Ondro, could you please verify that already released 2.4.3 package [1]
> contains that change so we don't need to patch ansible.cfg?

Yes, it works nice.

Comment 7 Martin Perina 2018-02-12 11:53:02 UTC
OK so closing based on above


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