Creating a Yum Repository

Armed with a few RPMs I need to install on multiple machines and sick of SCP’ing files around machines I decided to set up a Yum repository. Here’s how:

On a machine that already has Apache running and serving content:

yum install createrepo

cd /var/www/html/centos/5/qub/x86_64

createrepo /var/www/html/centos/5/qub/x86_64

Then on each client machine aiming to use this Yum repository:

cd /etc/yum.repos.d

vi myorg.repo

[myorg]
name=Centos-$releasever – MyOrg
baseurl=http://monitor.qub.ac.uk/centos/5/myorg/x86_64/
gpgcheck=0

Leave a Reply

  • (will not be published)

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>