Blame SPECS/rhel-system-roles.spec

617c05
Name: rhel-system-roles
617c05
Summary: Set of interfaces for unified system management
b30e92
Version: 1.0
d2325c
Release: 2%{?dist}
617c05
617c05
#Group: Development/Libraries
617c05
License: GPLv3+ and MIT and BSD
1d7625
%global rolecompatprefix rhel-system-roles.
1d7625
%global roleprefix linux-system-roles.
617c05
617c05
%global commit0 fe8bb81966b60fa8979f3816a12b0c7120d71140
617c05
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
617c05
%global rolename0 kdump
b30e92
%global version0 1.0.0-rc.1
617c05
617c05
%global commit1 43eec5668425d295dce3801216c19b1916df1f9b
617c05
%global shortcommit1 %(c=%{commit1}; echo ${c:0:7})
617c05
%global rolename1 postfix
617c05
%global version1 0.1
617c05
b30e92
%global commit2 6dd057aa434a31cb6ee67d02967362f9131e0c50
617c05
%global shortcommit2 %(c=%{commit2}; echo ${c:0:7})
617c05
%global rolename2 selinux
906ee8
#%%global version2 0.1
617c05
617c05
%global commit3 33a1a8c349de10d6281ed83d4c791e9177d7a141
617c05
%global shortcommit3 %(c=%{commit3}; echo ${c:0:7})
617c05
%global rolename3 timesync
b30e92
%global version3 1.0.0-rc.1
617c05
b30e92
%global commit5 d866422d9d73ed823632a3c56ee8575cd56cad5b
617c05
%global shortcommit5 %(c=%{commit5}; echo ${c:0:7})
617c05
%global rolename5 network
b30e92
#%%global version5 0.4
617c05
617c05
617c05
Source: https://github.com/linux-system-roles/%{rolename0}/archive/%{version0}.tar.gz#/%{rolename0}-%{version0}.tar.gz
617c05
Source1: https://github.com/linux-system-roles/%{rolename1}/archive/%{version1}.tar.gz#/%{rolename1}-%{version1}.tar.gz
906ee8
Source2: https://github.com/linux-system-roles/%{rolename2}/archive/%{commit2}.tar.gz#/%{rolename2}-%{shortcommit2}.tar.gz
617c05
Source3: https://github.com/linux-system-roles/%{rolename3}/archive/%{version3}.tar.gz#/%{rolename3}-%{version3}.tar.gz
b30e92
Source5: https://github.com/linux-system-roles/%{rolename5}/archive/%{commit5}.tar.gz#/%{rolename5}-%{shortcommit5}.tar.gz
1d7625
617c05
Source6: timesync-playbook.yml
617c05
Source7: timesync-pool-playbook.yml
617c05
617c05
Patch1: rhel-system-roles-%{rolename1}-prefix.diff
617c05
Patch2: rhel-system-roles-%{rolename2}-prefix.diff
617c05
Patch3: rhel-system-roles-%{rolename3}-prefix.diff
617c05
Patch5: rhel-system-roles-%{rolename5}-prefix.diff
617c05
617c05
Url: https://github.com/linux-system-roles/
617c05
BuildArch: noarch
617c05
617c05
%description
b30e92
Collection of Ansible roles and modules that provide a stable and
b30e92
consistent configuration interface for managing multiple versions
b30e92
of Red Hat Enterprise Linux.
617c05
d2325c
%package techpreview
d2325c
Summary: Set of interfaces for unified system management (tech preview)
d2325c
# to be updated when roles move to/from the main package to this one
d2325c
Conflicts: rhel-system-roles < 1.0-1
d2325c
d2325c
%description techpreview
d2325c
Collection of Ansible roles and modules that provide a consistent
d2325c
configuration interface for managing multiple versions of Red Hat
d2325c
Enterprise Linux.
d2325c
d2325c
The roles in this subpackage are available as Technology Preview
d2325c
and their backward compatibility is not guaranteed.
d2325c
617c05
617c05
%prep
b30e92
%setup -qc -a1 -a2 -a3 -a5
7185bc
cd %{rolename0}-%{version0}
d2325c
#kdump patches here if necessary
7185bc
cd ..
617c05
cd %{rolename1}-%{version1}
617c05
%patch1 -p1
617c05
cd ..
906ee8
cd %{rolename2}-%{commit2}
617c05
%patch2 -p1
617c05
cd ..
617c05
cd %{rolename3}-%{version3}
617c05
%patch3 -p1
617c05
cd ..
b30e92
cd %{rolename5}-%{commit5}
617c05
%patch5 -p1
617c05
cd ..
617c05
617c05
%build
617c05
617c05
%install
617c05
mkdir -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles
617c05
1d7625
cp -pR %{rolename0}-%{version0}      $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}%{rolename0}
1d7625
cp -pR %{rolename1}-%{version1}      $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}%{rolename1}
906ee8
cp -pR %{rolename2}-%{commit2}      $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}%{rolename2}
1d7625
cp -pR %{rolename3}-%{version3}      $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}%{rolename3}
b30e92
cp -pR %{rolename5}-%{commit5}      $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}%{rolename5}
1d7625
1d7625
ln -s    %{rolecompatprefix}%{rolename0}   $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{roleprefix}%{rolename0}
1d7625
ln -s    %{rolecompatprefix}%{rolename1}   $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{roleprefix}%{rolename1}
1d7625
ln -s    %{rolecompatprefix}%{rolename2}   $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{roleprefix}%{rolename2}
1d7625
ln -s    %{rolecompatprefix}%{rolename3}   $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{roleprefix}%{rolename3}
1d7625
ln -s    %{rolecompatprefix}%{rolename5}   $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{roleprefix}%{rolename5}
617c05
617c05
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/kdump
617c05
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/postfix
617c05
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/selinux
617c05
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/timesync
617c05
install -p -m 644 %{SOURCE6} $RPM_BUILD_ROOT%{_pkgdocdir}/timesync/example-timesync-playbook.yml
617c05
install -p -m 644 %{SOURCE7} $RPM_BUILD_ROOT%{_pkgdocdir}/timesync/example-timesync-pool-playbook.yml
617c05
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/network
617c05
1d7625
cp -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}kdump/README.md \
1d7625
    $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}kdump/COPYING \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/kdump
617c05
1d7625
cp -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}postfix/README.md \
1d7625
    $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}postfix/COPYING \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/postfix
617c05
1d7625
cp -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}selinux/README.md \
1d7625
    $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}selinux/COPYING \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/selinux
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}selinux/selinux-playbook.yml \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/selinux/example-selinux-playbook.yml
617c05
1d7625
cp -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}timesync/README.md \
1d7625
    $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}timesync/COPYING \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/timesync
617c05
1d7625
cp -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/README.md \
b30e92
    $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/LICENSE \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/network
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/bond-with-vlan.yml \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-bond-with-vlan-playbook.yml
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/bridge-with-vlan.yml \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-bridge-with-vlan-playbook.yml
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/eth-simple-auto.yml \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-eth-simple-auto-playbook.yml
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/eth-with-vlan.yml \
617c05
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-eth-with-vlan-playbook.yml
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/infiniband.yml \
1d7625
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-infiniband-playbook.yml
b30e92
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/macvlan.yml \
b30e92
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-macvlan-playbook.yml
b30e92
cp $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/remove-profile.yml \
b30e92
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-remove-profile-playbook.yml
b30e92
rm $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/remove-profile.yml
b30e92
cp $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/down-profile.yml \
b30e92
    $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-down-profile-playbook.yml
b30e92
rm $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/down-profile.yml
1d7625
mv $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/inventory \
617c05
   $RPM_BUILD_ROOT%{_pkgdocdir}/network/example-inventory
617c05
1d7625
rm $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/.gitignore
b30e92
rm $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/tests/.gitignore
b30e92
rm $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples/roles
1d7625
rmdir $RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolecompatprefix}network/examples
617c05
617c05
%files
1a3b94
%dir %{_datadir}/ansible
1a3b94
%dir %{_datadir}/ansible/roles
617c05
%{_datadir}/ansible/roles/%{roleprefix}kdump
617c05
%{_datadir}/ansible/roles/%{roleprefix}selinux
617c05
%{_datadir}/ansible/roles/%{roleprefix}timesync
617c05
%{_datadir}/ansible/roles/%{roleprefix}network
1d7625
%{_datadir}/ansible/roles/%{rolecompatprefix}kdump
1d7625
%{_datadir}/ansible/roles/%{rolecompatprefix}selinux
1d7625
%{_datadir}/ansible/roles/%{rolecompatprefix}timesync
1d7625
%{_datadir}/ansible/roles/%{rolecompatprefix}network
d2325c
# no examples for kdump yet
d2325c
#%%doc %%{_pkgdocdir}/kdump/example-*-playbook.yml
d2325c
%doc %{_pkgdocdir}/selinux/example-*-playbook.yml
d2325c
%doc %{_pkgdocdir}/timesync/example-*-playbook.yml
d2325c
%doc %{_pkgdocdir}/network/example-*-playbook.yml
d2325c
617c05
%doc %{_pkgdocdir}/network/example-inventory
d2325c
%doc %{_pkgdocdir}/kdump/README.md
d2325c
%doc %{_pkgdocdir}/selinux/README.md
d2325c
%doc %{_pkgdocdir}/timesync/README.md
d2325c
%doc %{_pkgdocdir}/network/README.md
1d7625
%doc %{_datadir}/ansible/roles/%{rolecompatprefix}kdump/README.md
1d7625
%doc %{_datadir}/ansible/roles/%{rolecompatprefix}selinux/README.md
1d7625
%doc %{_datadir}/ansible/roles/%{rolecompatprefix}timesync/README.md
1d7625
%doc %{_datadir}/ansible/roles/%{rolecompatprefix}network/README.md
617c05
617c05
617c05
%license %{_pkgdocdir}/*/COPYING
b30e92
%license %{_pkgdocdir}/*/LICENSE
1d7625
%license %{_datadir}/ansible/roles/%{rolecompatprefix}kdump/COPYING
1d7625
%license %{_datadir}/ansible/roles/%{rolecompatprefix}selinux/COPYING
1d7625
%license %{_datadir}/ansible/roles/%{rolecompatprefix}timesync/COPYING
b30e92
%license %{_datadir}/ansible/roles/%{rolecompatprefix}network/LICENSE
617c05
d2325c
%files techpreview
d2325c
%dir %{_datadir}/ansible
d2325c
%dir %{_datadir}/ansible/roles
b30e92
d2325c
%{_datadir}/ansible/roles/%{roleprefix}postfix
d2325c
%{_datadir}/ansible/roles/%{rolecompatprefix}postfix
d2325c
# no examples for postfix yet
d2325c
#%%doc %%{_pkgdocdir}/postfix/example-*-playbook.yml
b30e92
d2325c
%doc %{_pkgdocdir}/postfix/README.md
d2325c
%doc %{_datadir}/ansible/roles/%{rolecompatprefix}postfix/README.md
d2325c
%license %{_datadir}/ansible/roles/%{rolecompatprefix}postfix/COPYING
d2325c
d2325c
%changelog
b30e92
* Thu Aug  2 2018 Pavel Cahyna <pcahyna@redhat.com> - 1.0-2
b30e92
- Rebase the network role to the last revision (d866422).
b30e92
  Many improvements to tests, introduces autodetection of the current provider
b30e92
  and defaults to using profile name as interface name.
b30e92
- Update the description.
b30e92
b30e92
* Wed Aug  1 2018 Pavel Cahyna <pcahyna@redhat.com> - 1.0-1
b30e92
- Rebase the selinux, timesync and kdump roles to their 1.0rc1 versions.
b30e92
  Many changes to the role interfaces to make them more consistent
b30e92
  and conforming to Ansible best practices.
b30e92
- Split the postfix role into a -techpreview subpackage, we do not consider
b30e92
  it stable yet.
b30e92
0ecfb5
* Wed Mar 14 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-3
0ecfb5
- Minor corrections of the previous change by Till Maas.
0ecfb5
0ecfb5
* Fri Mar  9 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-2
0ecfb5
- Document network role options: static routes, ethernet, dns
0ecfb5
  Upstream PR#36, bz1550128, documents bz1487747 and bz1478576
0ecfb5
1a3b94
* Tue Jan 30 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-1
1a3b94
- Drop hard dependency on ansible (#1525655), patch from Yaakov Selkowitz
1a3b94
- Update the network role to version 0.4, solves bz#1487747, bz#1478576
1a3b94
7185bc
* Tue Dec 19 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-3
7185bc
- kdump: fix the wrong conditional for ssh checking and improve test (PR#10)
7185bc
7185bc
* Tue Nov 07 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-2
7185bc
- kdump: add ssh support. upstream PR#9, rhbz1478707
7185bc
906ee8
* Tue Oct 03 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-1
906ee8
- SELinux: fix policy reload when SELinux is disabled on CentOS/RHEL 6
906ee8
  (bz#1493574)
906ee8
- network: update to b856c7481bf5274d419f71fb62029ea0044b3ec1 :
906ee8
  makes the network role idempotent (bz#1476053) and fixes manual
906ee8
  network provider selection (bz#1485074).
906ee8
1d7625
* Mon Aug 28 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.4-1
1d7625
- network: update to b9b6f0a7969e400d8d6ba0ac97f69593aa1e8fa5:
1d7625
  ensure that state:absent followed by state:up works (bz#1478910), and change
1d7625
  the example IP adresses to the IANA-assigned ones.
1d7625
- SELinux: fix the case when SELinux is disabled (bz#1479546).
1d7625
1d7625
* Tue Aug 8 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.3-2
1d7625
- We can't change directories to symlinks (rpm bug #447156) so keep the old
1d7625
  names and create the new names as symlinks.
1d7625
1d7625
* Tue Aug 8 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.3-1
1d7625
- Change the prefix to linux-system-roles., keeping compatibility
1d7625
  symlinks.
1d7625
- Update the network role to dace7654feb7b5629ded0734c598e087c2713265:
1d7625
  adds InfiniBand support and other fixes.
1d7625
- Drop a patch included upstream.
1d7625
617c05
* Mon Jun 26 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.2-2
617c05
- Leave a copy of README and COPYING in every role's directory, as suggested by T. Bowling.
617c05
- Move the network example inventory to the documentation directory together.
617c05
  with the example playbooks and delete the now empty "examples" directory.
617c05
- Use proper reserved (by RFC 7042) MAC addresses in the network examples.
617c05
617c05
* Tue Jun 6 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.2-1
617c05
- Update the networking role to version 0.2 (#1459203)
617c05
- Version every role and the package separately. They live in separate repos
617c05
  and upstream release tags are not coordinated.
617c05
617c05
* Mon May 22 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.1-2
617c05
- Prefix the roles in examples and documentation with rhel-system-roles.
617c05
617c05
* Thu May 18 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.1-1
617c05
- Update to 0.1 (first upstream release).
617c05
- Remove the tuned role, it is not ready yet.
617c05
- Move the example playbooks to /usr/share/doc/rhel-system-roles/$SUBSYSTEM
617c05
  directly to get rid of an extra directory.
617c05
- Depend on ansible.
617c05
617c05
* Thu May 4 2017  Pavel Cahyna <pcahyna@redhat.com> - 0-0.1.20170504
617c05
- Initial release.
617c05
- kdump r. fe8bb81966b60fa8979f3816a12b0c7120d71140
617c05
- postfix r. 43eec5668425d295dce3801216c19b1916df1f9b
617c05
- selinux r. 1e4a21f929455e5e76dda0b12867abaa63795ae7
617c05
- timesync r. 33a1a8c349de10d6281ed83d4c791e9177d7a141
617c05
- tuned r. 2e8bb068b9815bc84287e9b6dc6177295ffdf38b
617c05
- network r. 03ff040df78a14409a0d89eba1235b8f3e50a750
617c05