Install newer yum and yum-utils on precise
Fixes ISO build failure. Apparently the version of yum (and yum-utils) shipped with precise is unable to handle OSCI repositories metadata. Change-Id: Icf1b4226b7b6a73da821cdc2fef60372b1b4c9a2 Closes-bug: #1381535
This commit is contained in:
parent
35eed79fd6
commit
0d3f162547
|
@ -20,6 +20,22 @@
|
|||
# - We need not try to install rubygems on trusty, because it doesn't exists
|
||||
# - We also should use multistrap version 2.1.6 from devops mirror
|
||||
|
||||
# install yum and yum-utils from trusty, so it can handle the meta-data
|
||||
# of OSCI rpm repositories. Works around ISO build failure (LP #1381535).
|
||||
update_yum_utils ()
|
||||
{
|
||||
local pkgs="yum_3.4.3-2ubuntu1_all.deb yum-utils_1.1.31-2_all.deb"
|
||||
# required for new yum-utils
|
||||
local deps="python-iniparse"
|
||||
local mirror="https://launchpad.net/ubuntu/+archive/primary/+files"
|
||||
sudo apt-get install $deps
|
||||
for pkg in $pkgs; do
|
||||
rm -f $pkg >/dev/null 2>&1
|
||||
wget "${mirror}/${pkg}"
|
||||
sudo dpkg -i $pkg
|
||||
done
|
||||
}
|
||||
|
||||
DISTRO=$(lsb_release -c -s)
|
||||
|
||||
case "${DISTRO}" in
|
||||
|
@ -119,6 +135,12 @@ else
|
|||
echo "`whoami` ALL=(ALL) NOPASSWD: ALL" | sudo tee -a /etc/sudoers
|
||||
fi
|
||||
|
||||
case "${DISTRO}" in
|
||||
precise)
|
||||
update_yum_utils
|
||||
;;
|
||||
esac
|
||||
|
||||
# Fix tmp folder ownership
|
||||
[ -d ~/tmp ] && sudo chown -R `whoami`.`id -gn` ~/tmp || mkdir ~/tmp
|
||||
|
||||
|
|
Loading…
Reference in New Issue