Update apt cache before installing UCA keyring

add-apt-repository will attempt to install the ubuntu-cloud-keyring package.
Call 'apt-get update' first to ensure the local cache is up to date and the
package can be found.

This also updates dsg to only set this up if running on Precise.

Change-Id: Ie349e89ef20ac4c526c8353cf4aabe3ddad73824
Partial-bug: #1326754.
This commit is contained in:
Adam Gandelman 2014-06-09 13:37:33 -07:00
parent b4e700e403
commit 33275e78f4

@ -601,9 +601,13 @@
r="$r tempest.scenario.test_baremetal_basic_ops"
export DEVSTACK_GATE_TEMPEST_REGEX="$r"
# pull in libvirt /w ovs support from ubuntu cloud-archive.
sudo add-apt-repository cloud-archive:icehouse
sudo apt-get update
if $(grep -Eqs 'Ubuntu 12.04' /etc/lsb-release); then
# pull in libvirt /w ovs support from ubuntu cloud-archive for
# Precise.
sudo apt-get update
sudo add-apt-repository cloud-archive:icehouse
sudo apt-get update
fi
# prevent sshd from jumping to the ovs bridge on Precise instances.
IP=$(ip addr show eth0 | grep 'inet ' | sed 's/inet \([0-9\.]*\)\/.*/\1/' | tr -d ' ')