Public domain
#!/bin/bash
TMP=$(mktemp -d)
CWD=$(dirname $(readlink -f $0))
MIRROR="http://vault.centos.org/5.2/os/i386/CentOS"
PKGS="
yum-3.2.8-9.el5.centos.1.noarch.rpm
python-elementtree-1.2.6-5.i386.rpm
python-iniparse-0.2.3-4.el5.noarch.rpm
python-sqlite-1.1.7-1.2.1.i386.rpm
rpm-python-4.4.2-48.el5.i386.rpm
python-urlgrabber-3.1.0-2.noarch.rpm
yum-metadata-parser-1.1.2-2.el5.i386.rpm
m2crypto-0.16-6.el5.2.i386.rpm
"
cd ${TMP}
for PKG in ${PKGS}; do
wget "${MIRROR}/${PKG}"
done
rpm -Uvh *.rpm
cd ${CWD}
rm -rf ${TMP}
BY: Pejman Moghadam
TAG: yum, centos
DATE: 2012-04-02 18:25:57