Ubuntu apt
From Lolly's Wiki
Configuring a proxy for apt
Put this into your /etc/apt/apt.conf.d/00proxy :
// Options for the downloading routines
Acquire
{
Queue-Mode "host"; // host|access
Retries "0";
Source-Symlinks "true";
// HTTP method configuration
http
{
//Proxy::http.us.debian.org "DIRECT"; // Specific per-host setting
Proxy "http://<user>:<password>@<proxy-host>:<proxy-port>";
Timeout "120";
Pipeline-Depth "5";
// Cache Control. Note these do not work with Squid 2.0.2
No-Cache "false";
Max-Age "86400"; // 1 Day age on index files
No-Store "false"; // Prevent the cache from storing archives
};
ftp
{
Proxy "http://<user>:<password>@<proxy-host>:<proxy-port>";
//Proxy::http.us.debian.org "DIRECT"; // Specific per-host setting
Timeout "120";
/* Passive mode control, proxy, non-proxy and per-host. Pasv mode
is prefered if possible */
Passive "true";
Proxy::Passive "true";
Passive::http.us.debian.org "true"; // Specific per-host setting
};
cdrom
{
mount "/cdrom";
// You need the trailing slash!
"/cdrom"
{
Mount "sleep 1000";
UMount "sleep 500";
}
};
};