Skip to content
Snippets Groups Projects
Commit 0bacf3f5 authored by Stéphane Diemer's avatar Stéphane Diemer
Browse files

Added some log in APT setup.

parent bbaceb24
No related branches found
No related tags found
No related merge requests found
...@@ -3,7 +3,7 @@ source /root/envsetup/conf.sh ...@@ -3,7 +3,7 @@ source /root/envsetup/conf.sh
# migrate to Ubuntu 16.04 / apply sources.list # migrate to Ubuntu 16.04 / apply sources.list
if ( rgrep '14.04' /etc/lsb-release >/dev/null ); then if ( rgrep '14.04' /etc/lsb-release >/dev/null ); then
# upgrade to Ubuntu 16.04 echo "Upgrading to Ubuntu 16.04."
apt-get update apt-get update
apt-get dist-upgrade -y apt-get dist-upgrade -y
cp sources16.list /etc/apt/sources.list cp sources16.list /etc/apt/sources.list
...@@ -12,7 +12,7 @@ if ( rgrep '14.04' /etc/lsb-release >/dev/null ); then ...@@ -12,7 +12,7 @@ if ( rgrep '14.04' /etc/lsb-release >/dev/null ); then
apt-get install -f -y apt-get install -f -y
apt-get dist-upgrade -y apt-get dist-upgrade -y
else else
# Ubuntu 16.04 echo "Updating Ubuntu 16.04 sources.list."
cp sources16.list /etc/apt/sources.list cp sources16.list /etc/apt/sources.list
fi fi
...@@ -23,15 +23,18 @@ apt-get install -y aptitude apt-transport-https ...@@ -23,15 +23,18 @@ apt-get install -y aptitude apt-transport-https
# modify sources.list to use ubicast cache # modify sources.list to use ubicast cache
if ( ! grep ${APT_CACHE_HOST} /etc/apt/sources.list ); then if ( ! grep ${APT_CACHE_HOST} /etc/apt/sources.list ); then
echo "Updating sources.list to use cache ${APT_CACHE_HOST}."
sed -i "s@http://@http://${APT_CACHE_HOST}/@" /etc/apt/sources.list sed -i "s@http://@http://${APT_CACHE_HOST}/@" /etc/apt/sources.list
fi fi
# APT panel # APT panel
echo "Adding skyreach.list to APT sources."
wget -q "https://${SKYREACH_HOST}/media/public.gpg" -O- | sudo apt-key add - wget -q "https://${SKYREACH_HOST}/media/public.gpg" -O- | sudo apt-key add -
echo "deb https://${SKYREACH_HOST} packaging/apt/${SKYREACH_API_KEY}/" > /etc/apt/sources.list.d/skyreach.list echo "deb https://${SKYREACH_HOST} packaging/apt/${SKYREACH_API_KEY}/" > /etc/apt/sources.list.d/skyreach.list
apt-get update apt-get update
# unattended-upgrades # unattended-upgrades
echo "Installing and configuring unattended-upgrades."
apt-get install -y unattended-upgrades apt-get install -y unattended-upgrades
sed -i 's@//Unattended-Upgrade::Mail "root";@Unattended-Upgrade::Mail "root";@' /etc/apt/apt.conf.d/50unattended-upgrades sed -i 's@//Unattended-Upgrade::Mail "root";@Unattended-Upgrade::Mail "root";@' /etc/apt/apt.conf.d/50unattended-upgrades
sed -i 's@//*.*"vim";@"mysql-server";@' /etc/apt/apt.conf.d/50unattended-upgrades sed -i 's@//*.*"vim";@"mysql-server";@' /etc/apt/apt.conf.d/50unattended-upgrades
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment