Public Repository

Last pushed: 6 months ago
Short Description
Stage3 with a few adjustments.
Full Description

This is a stage3 import with some extra tweaks to make it a decent base image. I will, at some point, try to make it smaller by purging some of the bloat. It isn't made via Dockerfile currently, I need to decide what I'll do about that.

Some important notes:

Volumes to mount:

/usr/portage:/usr/portage:ro
/container/gentoo/packages:/packages
/container/gentoo/distfiles:/distfiles

The first one should be adjusted if you're not running a gentoo host system.

In make.conf we set:

  • To prevent portage trying to download files here but use them if they're there
    PORTAGE_RO_DISTDIRS="/usr/portage/distfiles"
  • Where it should download to if they aren't there, this should definitely be volume mounted
    DISTDIR="/distfiles"
    • We build packages to speed rebuilds
      PKGDIR="/packages"
  • For those packages
    EMERGE_DEFAULT_OPTS="-kb"
  • the latter one allows for concurrent packages for the same version of a package. See man page for make.conf
    FEATURES="buildpkg binpkg-multi-instance"

Commands...

  • Don't need cgroups here
    sed -i 's/#?rc_controller_cgroups=".*"/rc_controller_cgroups="NO"/' /etc/rc.conf
  • This is to talk gentoo in to not looking for kernel related things
    sed -i 's/#?rc_sys=".*"/rc_sys="docker"/' /etc/rc.conf
  • Because these as files is lame
    mkdir -p /etc/portage/package.accept_keywords /etc/portage/package.use /etc/portage/package.mask

Use flags set...

  • This is to fix an issue I was having with crypto conflicts on a container that inherits this one
    dev-vcs/git -gpg

Final emerge

  • In addition to trying to make this fully updated, we install a few packages that come in handy for building and working within most images.
    emerge --newuse --deep --with-bdeps=y @system @world monit tmux app-misc/screen dev-vcs/git vim nano gentoolkit
  • Make sure we kill off the extra junk
    emerge --depclean
Docker Pull Command
Owner
kaithar

Comments (0)