aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorSamYaple <sam@yaple.net>2016-02-12 02:16:12 +0000
committerSamYaple <sam@yaple.net>2016-02-12 03:38:48 +0000
commit44a4682da288508db3c995e98bf32fc658d109e0 (patch)
tree1629107a3a9c7ff516553fba99d0b06765e97a93 /tools
parent9f7c3b630d0c1f3902063c03588c04dd84bd36ea (diff)
downloadkolla-44a4682da288508db3c995e98bf32fc658d109e0.tar.gz
kolla-44a4682da288508db3c995e98bf32fc658d109e0.zip
Fix detect_distro
It was run before ansible was installed and did not properly fail. This prevented the mirrors for apt from being properly used. TrivialFix Change-Id: I5331020993b62c8635a4a97dc3a3d2e01e3d4360
Diffstat (limited to 'tools')
-rwxr-xr-xtools/setup_gate.sh13
1 files changed, 8 insertions, 5 deletions
diff --git a/tools/setup_gate.sh b/tools/setup_gate.sh
index 882f0e00f..c701e10ed 100755
--- a/tools/setup_gate.sh
+++ b/tools/setup_gate.sh
@@ -14,7 +14,14 @@ function setup_config {
# Copy configs
sudo cp -a etc/kolla /etc/
+ # Use Infra provided pypi
+ echo "RUN echo $(base64 -w0 /etc/pip.conf) | base64 -d > /etc/pip.conf" | sudo tee /etc/kolla/header
+ sed -i 's|^#include_header.*|include_header = /etc/kolla/header|' /etc/kolla/kolla-build.conf
+
if [[ "${DISTRO}" == "Debian" ]]; then
+ # Infra does not sign thier mirrors so we ignore gpg signing in the gate
+ echo "RUN echo 'APT::Get::AllowUnauthenticated \"true\";' > /etc/apt/apt.conf" | sudo tee -a /etc/kolla/header
+
# Optimize the repos to take advantage of the Infra provided mirrors for Ubuntu
sed -i 's|^#apt_sources_list.*|apt_sources_list = /etc/kolla/sources.list|' /etc/kolla/kolla-build.conf
sudo cp /etc/apt/sources.list /etc/kolla/sources.list
@@ -26,10 +33,6 @@ deb http://repo.percona.com/apt trusty main
deb http://download.ceph.com/debian-hammer/ trusty main
EOF
fi
-
- # Use Infra provided pypi
- echo "RUN echo $(base64 -w0 /etc/pip.conf) | base64 -d > /etc/pip.conf" | sudo tee /etc/kolla/header
- sed -i 's|^#include_header.*|include_header = /etc/kolla/header|' /etc/kolla/kolla-build.conf
}
function detect_distro {
@@ -79,6 +82,7 @@ function setup_ansible {
mkdir /tmp/kolla
sudo -H pip install "ansible<2" "docker-py>=1.6.0"
+ detect_distro
setup_inventory
@@ -100,7 +104,6 @@ function setup_logging {
mkdir -p /tmp/logs/{ansible,build}
}
-detect_distro
setup_logging
tools/dump_info.sh
setup_ssh