Set up a repository cache on your network so that once a Linux package is downloaded from an official repository, all other machines will download it from your local area network.
Builds of the image are available on Docker Hub.
docker pull codeworksio/apt-cacher-ng
Alternatively you can build the image yourself.
docker build --tag codeworksio/apt-cacher-ng \
github.com/codeworksio/docker-apt-cacher-ng
Start container using:
docker run --detach --restart always \
--name apt-cacher-ng \
--hostname apt-cacher-ng \
--publish 3142:3142 \
codeworksio/apt-cacher-ng
After starting up an instance of the Apt-Cacher NG server we can build other containers with the following command
make build APT_PROXY=localhost:3142