.deb package-manager and proxy settings

This question comes back very very often on unbuntuforums: how to update/upgrade/install packages when connected to the Internet via a proxy. Actually, all the front-ends to APT (Advance Packaging Tool), namely apt-get, aptitude, synaptic and adept, can get the proxy settings from the /etc/apt/apt.conf file and do not read the global proxy settings.

The syntax is the following:

ACQUIRE {
http::proxy "http://user:password@host:port"
};

With no authentication required, the apt.conf file I use when at work is:

ACQUIRE {
http::proxy "http://myproxy.myhost.fr:3128"
};

To be noted, the trailing semicolon is required.

So this is a laptop. When at home, with no proxy set up, I use this file:

ACQUIRE {http::proxy "direct"};

edit : Thanks Stemp (the Great Bug Warrior ;-D) for giving me the link to this bug. Hopefully, it will get fixed.

Reference

http://www.die.net/doc/linux/man/man5/apt.conf.5.html

3 thoughts on “.deb package-manager and proxy settings

  1. bapoumba

    I do not know. It’ like Firefox having its own proxy menu to be independent of environment variables, and thus being used on different OS and desktops. What about KDE proxy settings ? ;-)

Comments are closed.