# special thanks to kkeithley for using his wizard rpm skills to get this going %global puppet_module_version __VERSION__ Name: puppet-gluster Version: __VERSION__ #Release: __RELEASE__%{?dist} # use this to make dist specific builds Release: __RELEASE__ Summary: A puppet module for GlusterFS License: AGPLv3+ URL: https://github.com/purpleidea/puppet-gluster Source0: https://download.gluster.org/pub/gluster/purpleidea/puppet-gluster/SOURCES/puppet-gluster-%{puppet_module_version}.tar.bz2 BuildArch: noarch Requires: puppet >= 3.0.0 Requires: puppetlabs-stdlib >= 4.1.0 # these should be 'Suggests:' or similar, since they aren't absolutely required #Requires: puppetlabs-apt >= 1.4.0 Requires: puppet-common >= 0.0.1 Requires: puppet-keepalived >= 0.0.1 Requires: puppet-puppet >= 0.0.1 Requires: puppet-shorewall >= 0.0.1 Requires: puppet-yum >= 0.0.1 %description A puppet module used for installing, configuring and managing GlusterFS. %prep %setup -c -q -T -D -a 0 find %{_builddir} -type f -name ".*" -exec rm {} + find %{_builddir} -size 0 -exec rm {} + find %{_builddir} \( -name "*.pl" -o -name "*.sh" \) -exec chmod +x {} + find %{_builddir} \( -name "*.pp" -o -name "*.py" \) -exec chmod -x {} + find %{_builddir} \( -name "*.rb" -o -name "*.erb" \) -exec chmod -x {} + -exec sed -i "/^#!/{d;q}" {} + %build %install rm -rf %{buildroot} # _datadir is typically /usr/share/ install -d -m 0755 %{buildroot}/%{_datadir}/puppet/modules/ cp -r puppet-gluster-%{puppet_module_version} %{buildroot}/%{_datadir}/puppet/modules/gluster %files %{_datadir}/puppet/modules/* # this changelog is auto-generated by git log %changelog