%global _unitdir /usr/lib/systemd/system Name: nodesync Version: 0.2 Release: 1%{?dist} Summary: Nodesync tool for YUM transactions and files sync Group: Applications/System License: ASL 2.0 URL: http://trac.grid.org.ua/repos/workarea/nodesync # The source was created from a svn checkout # svn export http://trac.grid.org.ua/repos/workarea/nodesync nodesync # tar -z -c -f nodesync.tar.gz nodesync Source0: nodesync.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch Requires: autofs Requires: bash-completion %description Nodesync is a shared-folder based sync tool that syncronize YUM transactions and set of files between common working nodes. %prep %setup -q -n nodesync %build %install rm -rf %{buildroot} mkdir -p %{buildroot}%{_sbindir} mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d mkdir -p %{buildroot}%{_sysconfdir}/profile.d mkdir -p %{buildroot}%{_sysconfdir}/cron.d mkdir -p %{buildroot}%{_localstatedir}/spool/nodesync mkdir -p %{buildroot}%{_unitdir} install -pm 755 nodesync \ %{buildroot}%{_sbindir} install -pm 644 nodesync.bash_completion \ %{buildroot}%{_sysconfdir}/bash_completion.d/nodesync install -pm 644 nodesync_yum.sh \ %{buildroot}%{_sysconfdir}/profile.d install -pm 644 nodesync.cron \ %{buildroot}%{_sysconfdir}/cron.d/nodesync install -pm 644 nodesync.service \ %{buildroot}%{_unitdir} %post /usr/bin/systemctl enable nodesync.service %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %{_sbindir}/nodesync %{_sysconfdir}/bash_completion.d/nodesync %{_sysconfdir}/cron.d/nodesync %{_sysconfdir}/profile.d/nodesync_yum.sh %{_unitdir}/nodesync.service %dir %{_localstatedir}/spool/nodesync %changelog * Mon Jul 28 2014 Andrii Salnikov - 0.2-1 - Cron/Systemd sync - YUM conditional enable * Mon Jul 28 2014 Andrii Salnikov - 0.1-2 - Initial nodesync version