gentoo-python: Remove Python 2
Portage runs fine on Python 3, and there's no need to have multiple
versions of Python installed. Removing it here allows us to trim down
to smaller images, because Python's pretty heavy:
$ docker run -i -t --rm wking/gentoo-portage:
20140717 /bin/bash
d1cdbe4c737a / # du -hs /usr/lib64/python2.7/
66M /usr/lib64/python2.7/
My current trimmed ngircd is only image is 341 MB:
$ docker images wking/ngircd-trimmed | grep
20140717
wking/ngircd-trimmed
20140717 98daec1a09c5 16 hours ago 340.9 MB
so about 20% of the trimmed image is a useless old Python version. We
could shrink the trimmed image even more by removing Portage and
Python 3, but that requires some external-to-Portage hackery. This is
easy to do, and folks who *do* need Python 2 can easily adjust their
PYTHON_TARGETS, PYTHON_SINGLE_TARGET, eselected Python, and re-emerge.
We only need to emerge @system, because @world is still empty at this
point.