Proxying Debian/Ubuntu repositories

On the server,

apt install apt-cacher-ng
systemctl status apt-cacher-ng
cd /etc/apt-cacher-ng
cp -pi acng.conf acng.conf.dist
egrep '^CacheDir|^LogDir' acng.conf
netstat -antupe --inet --inet6 | grep 3142
#lynx localhost:3142

then after some time you may,

du -sh /var/cache/apt-cacher-ng

On the clients (incl. the server itself),

vi /etc/apt/apt.conf.d/02proxy

Acquire::http { Proxy "http://x.x.x.x:3142"; };

apt update

Refs.