a Debian/Ubuntu package proxy
Ubuntu
apt install apt-cacher-ng systemctl status apt-cacher-ng cd /etc/apt-cacher-ng/
Slackware - look for latest and build it
wget http://ftp.debian.org/debian/pool/main/a/apt-cacher-ng/apt-cacher-ng_3.2.orig.tar.xz tar xJf apt-cacher-ng_3.2.orig.tar.xz cd apt-cacher-ng-3.2/ #grep -i wrap CMakeLists.txt mkdir build cd build cmake .. make -j5 make install cd /usr/local/etc/apt-cacher-ng/
mv -i acng.conf acng.conf.dist sed -r '/^[[:space:]]*(#|$)/d' acng.conf.dist > acng.conf egrep '^CacheDir|^LogDir' acng.conf ls -al /var/log/apt-cacher-ng/ ls -al /var/cache/apt-cacher-ng/ # slackware mkdir -p /var/log/apt-cacher-ng/ mkdir -p /var/cache/apt-cacher-ng/
slackware w/ v3.2.orig w/o libwrap, fix empty Sourceforge mirror list and eventually HTTPS links to pass through
vi acng.conf #Remap-sfnet: file:sfnet_mirrors UseWrap: 0 PassThroughPattern: .*
netstat -lntup | grep 3142 http://x.x.x.x:3142
tail -F /var/log/apt-cacher-ng/apt-cacher.{err,log}
start & enable at boot time
vi /etc/rc.local echo -n starting apt-cacher-ng... /usr/local/sbin/apt-cacher-ng -c /usr/local/etc/apt-cacher-ng && echo done || echo FAILED
status
pgrep -a apt-cacher-ng ps auxfww | grep cacher | grep -v grep netstat -lntup --inet --inet6 | grep cacher
stop
pkill apt-cacher-ng
after a while
find /var/cache/apt-cacher-ng/ du -sh /var/cache/apt-cacher-ng/
nmap -p 3142 x.x.x.x vi /etc/apt/apt.conf.d/02proxy Acquire::http { Proxy "http://x.x.x.x:3142"; }; apt update
Apt-Cacher NG https://www.unix-ag.uni-kl.de/~bloch/acng/
Setting up an ‘Apt-Cache’ Server Using ‘Apt-Cacher-NG’ in Ubuntu 14.04 Server https://www.tecmint.com/apt-cache-server-in-ubuntu/
riot-web repo does not work with apt-cacher-ng #3573 https://github.com/vector-im/riot-web/issues/3573