sudo yum -y install https://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-8.noarch.rpm
sudo yum -y install mock rpm-build rpmdevtools git
sudo usermod -a -G mock $(id -un)
ls rhel/SPECS/*.spec | xargs -n 1 spectool -g -C rhel/SOURCES
rpmbuild --define "_topdir rhel" -bs rhel/SPECS/*.spec
- Build Go programming language rpm (build dependency for other rpms)
mockchain -c -r epel-7-x86_64 -l result-repo rhel/SRPMS/golang-1.7.3-*.src.rpm
mockchain -c -r epel-7-x86_64 -l result-repo rhel/SRPMS/*.src.rpm
ls result-repo/results/epel-7-x86_64/*/*.rpm