Published on Stefano Sasso (http://stefano.dscnet.org)
apt-cacher: una cache per pacchetti deb
By stefano
Data di creazione 08/12/2007 - 17:11

# apt-get install apt-cacher

Per fare in modo che apt-cacher parta al boot è necessario modificare il file /etc/default/apt-cacher ponendo ad 1 il valore di AUTOSTART

la configurazione di fa da /etc/apt-cacher/apt-cacher.conf

cache_dir=/var/cache/apt-cacher
admin_email=root@localhost
daemon_port=3142
group=www-data # devono avere permessi per scrivere nella cache_dir!
user=www-data
allowed_hosts=*
denied_hosts=10.0.0.0/24,192.168.1.133,192.168.0.3-192.168.0.56
allowed_hosts_6=fec0::/16
denied_hosts_6=
# limita gli accessi ai mirror debian a seconda del nome
#allowed_locations=ftp.uni-kl.de,ftp.nerim.net,debian.tu-bs.de
http_proxy=proxy.example.com:8080
use_proxy=0
http_proxy_auth=proxyuser:proxypass
use_proxy_auth=0
# Rate limiting sets the maximum bandwidth in bytes per second to use
# for fetching packages. Syntax is fully defined in 'man wget'.
# Use 'k' or 'm' to use kilobits or megabits / second: eg, 'limit=25k'.
# Use 0 or a negative value for no rate limiting.
limit=0

per quanto riguarda la configurazione dei client, se prima il file sources.list era

deb http://ftp.it.debian.org/debian [1] unstable main contrib non-free
ora dovrà diventare
deb http://server:3142/ftp.it.debian.org/debian [2] unstable main contriib non-free
Creative Commons License Linux Kernel Debian GNU/Linux Apache Web Server Drupal CMS gnustile.net

Source URL (retrieved on 05/02/2012 - 14:44): http://stefano.dscnet.org/a/apt_cache_una_cache_pacchetti_deb

Links:
[1] http://ftp.it.debian.org/debian
[2] http://server:3142/ftp.it.debian.org/debian