Remove services containers dont need by default

Ubuntu Xenial adds several services to its base image that we don't
need by default. These packages start services and are being started on
all containers we run. This consuming resources and is making our base
images a little larger than they need to be. This change purges those
packages which removes the services.

Change-Id: I26ed9e26e5b0812ffdd198d9838f7aacefead3a1
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
This commit is contained in:
Kevin Carter 2017-04-26 08:42:39 -05:00 committed by Kevin Carter (cloudnull)
parent 338c31ef3b
commit 39135eb4b8

View File

@ -66,6 +66,7 @@ lxc_cache_map:
apt-key add /root/repo.keys
rm /root/repo.keys
export DEBIAN_FRONTEND=noninteractive
apt-get remove -y --purge snap* lxc* lxd* || true
apt-get update
apt-get install -y {{ lxc_cache_install_debconf }} {{ lxc_cache_distro_packages | join(' ') }}
apt-get upgrade -y {{ lxc_cache_install_debconf }}