Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
41 lines (24 sloc) 990 Bytes

A Recipe for a Redis RPM on CentOS

Perform the following on a build box as root.

Create an RPM Build Environment

sudo rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-4.noarch.rpm 
sudo yum install rpmdevtools
rpmdev-setuptree

Install Prerequisites for RPM Creation

sudo yum groupinstall 'Development Tools'

Download Redis

cd /tmp
wget http://redis.googlecode.com/files/redis-2.2.4.tar.gz
cp redis-2.2.4.tar.gz ~/rpmbuild/SOURCES/

Get Necessary System-specific Configs

git clone git://github.com/esminc/redis-centos.git
cp redis-centos/conf/* ~/rpmbuild/SOURCES/
cp redis-centos/spec/* ~/rpmbuild/SPECS/

Build the RPM

cd ~/rpmbuild/
rpmbuild -ba SPECS/redis.spec

The resulting RPM will be:

~/rpmbuild/RPMS/x86_64/redis-2.0.4-1.x86_64.rpm

Credits

Based on the redis.spec file from Jason Priebe, found on Google Code.