Skip to content

Commit

Permalink
put our ansible roles in standard location
Browse files Browse the repository at this point in the history
the share directory is the standard location for installing ansible playbooks
this puts our playbooks into that location so they can be picked up
without the need to modify the load path

Move ansible playbooks to standard location

This lets us drop custom path definition and remove the need to introduce
any configuration changes.
  • Loading branch information
kbrock committed Aug 19, 2021
1 parent 1dca31f commit 9ad151c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
11 changes: 6 additions & 5 deletions rpm_spec/manageiq.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,12 @@ cd %{_builddir}
#sample configuration files
%{__mv} %{buildroot}%{app_root}/config/cable.yml.sample %{buildroot}%{app_root}/config/cable.yml

# Move roles to playbook share
mkdir -p %{buildroot}/usr/share/ansible/roles/
for i in %{buildroot}%{app_root}/content/ansible_consolidated/roles/* ; do
%{__mv} $i %{buildroot}/usr/share/ansible/roles/
done

## from appliance
#symlink some executables
%{__mkdir} -p %{buildroot}/%{_bindir}
Expand All @@ -123,11 +129,6 @@ pushd ./%{appliance_builddir}/LINK/etc
done
popd

%{__mkdir} -p %{buildroot}/root
pushd ./%{appliance_builddir}/LINK/root
ln -s %{appliance_root}/LINK/root/.ansible.cfg %{buildroot}/root/.ansible.cfg
popd

pushd ./%{appliance_builddir}/LINK
ln -s %{appliance_root}/LINK/.toprc %{buildroot}/.toprc
popd
Expand Down
1 change: 1 addition & 0 deletions rpm_spec/subpackages/manageiq-core
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,4 @@ done
%exclude %{app_root}/public/ui
%exclude %{app_root}/public/upload
%exclude %{app_root}/log/apache
/usr/share/ansible/roles/
1 change: 0 additions & 1 deletion rpm_spec/subpackages/manageiq-system
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ Requires: openldap-clients
%files system
%defattr(-,root,root,-)
/.toprc
/root/.ansible.cfg
%{appliance_root}
%{app_root}/log/apache
%dir %{manifest_root}
Expand Down

0 comments on commit 9ad151c

Please sign in to comment.