Let us create local repository for CDH5, it contain packages related to HDFS, YARN, Spark etc.
- Download cloudera-cdh5.repo
- Run reposync to copy RPMs locally
- Make sure RPMs are in the location that is being served by baseurl in repo file
- Go to the baseurl and run createrepo so that repodata directory is created
- Go to the gpg key url and make sure gpg key is downloaded.
- Make sure to update the URLs in repo files pointing to local repositories. Also validate by using browser by copy pasting the baseurl.
- Make sure URLs are using http not https in our case.
https://gist.github.com/dgadiraju/acce88c75ad0021c46b05c30d68e247b