MAINTAINER ${MAINTAINER}
#VOLUME ["${PORTAGE}:/usr/portage:ro", "${PORTAGE}/distfiles:/usr/portage/distfiles:rw"]
RUN echo 'USE="${USE} sqlite"' >> /etc/portage/make.conf
-RUN echo 'PYTHON_TARGETS="python2_7"' >> /etc/portage/make.conf
-RUN echo 'PYTHON_SINGLE_TARGET="python2_7"' >> /etc/portage/make.conf
+RUN sed -i 's/\(PYTHON_TARGETS\)=.*/\1="python2_7"/' /etc/portage/make.conf
+RUN sed -i 's/\(PYTHON_SINGLE_TARGET\)=.*/\1="python2_7"/' /etc/portage/make.conf
RUN echo 'USE_PYTHON="2.7"' >> /etc/portage/make.conf
+RUN emerge -v --newuse --deep --with-bdeps=y @system @world
+RUN eselect python set $(eselect python show --python2)
ADD package.accept_keywords /etc/portage/package.accept_keywords
RUN emerge -v dev-python/blinker dev-python/boto dev-python/backports-lzma dev-python/flask dev-python/gevent dev-python/pyyaml dev-python/redis-py dev-python/requests dev-python/rsa dev-python/simplejson dev-python/sqlalchemy dev-vcs/git www-servers/gunicorn
RUN eselect news read new