Sometimes, trove image builds fail because of package authentication issues. This is often times related to the inability to get to a key server, and not indicative of anything more serious than that. The (strongly discouraged in production use cases) workaround for this is to pass the --allow-unauthenticated option to apt-get install. I say 'Closes-Bug' below but I realize that this is a white lie. What it fixes is only the Trove elements. The image build process uses elements from other places (triple-o, for example). These can still fail for the same reason. There is a much bigger hammer that we can use if we need it, and that is to throw the line 'APT::Get::AllowUnauthenticated "true";' into a conf file in /etc/apt/apt.conf.d/. If this hammer isn't big enough, we can revist later. Change-Id: I009697332bb2a8e1e60b17c10944faed5c311da3 Closes-Bug:#1646856
33 lines
712 B
Bash
Executable File
33 lines
712 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# CONTEXT: GUEST during CONSTRUCTION as ROOT
|
|
# PURPOSE: Install controller base required packages
|
|
|
|
set -e
|
|
set -o xtrace
|
|
|
|
export DEBIAN_FRONTEND=noninteractive
|
|
|
|
add-apt-repository 'deb http://archive.ubuntu.com/ubuntu trusty universe'
|
|
apt-get -y update
|
|
|
|
apt-get --allow-unauthenticated -y install mysql-client-5.6 mysql-server-5.6 percona-xtrabackup${PXB_VERSION_OVERRIDE}
|
|
|
|
cat >/etc/mysql/conf.d/no_perf_schema.cnf <<_EOF_
|
|
[mysqld]
|
|
performance_schema = off
|
|
_EOF_
|
|
|
|
mv /etc/mysql/my.cnf.fallback /etc/mysql/my.cnf
|
|
chown mysql:mysql /etc/mysql/my.cnf
|
|
cat >/etc/mysql/my.cnf <<_EOF_
|
|
[mysql]
|
|
|
|
!includedir /etc/mysql/conf.d/
|
|
_EOF_
|
|
|
|
rm /etc/init/mysql.conf
|
|
systemctl daemon-reload
|
|
systemctl enable mysql
|
|
|