woensdag 31 oktober 2007

Using proxy with Debian for apt-get(or Ubuntu) and other apps

If you are in a corporate environment you probably need to pass through a proxy to get on the internet.

The same for getting your debian/ubuntu packages.
You can easily configure this.

There are two possibilities:
  1. Define http_proxy variable for HTTP
    export http_proxy="http://user:password@proxy-dns-name-or-ip:portnumber"
    If you want to use this in a script, make sure you run it as follows:
    . ./proxy-script
    For FTP it is slightly different:
    export ftp_proxy="http://user:password@proxy-dns-name-or-ip:portnumber"
    For RSYNC (NOTICE that there is NO http:// at the start of the value):
    export rsync_proxy="user:password@proxy-dns-name-or-ip:portnumber"
  2. Adding this to the apt.conf file (does only makes apt-get to use the proxy)
    Aqcuire::http::Proxy "http://user:password@proxy-dns-name-or-ip:portnumber"
This will work for alot of shell tools (ftp, wget, ...) but some programs do create there own system for using a proxy.
  1. Firefox: "Edit", "Preferences", "Advanced", "Network", "Settings" and then select "Auto-detect proxy settings for this network"
  2. In KDE you can also change the proxy using the Control Center. Just search on proxy and you will find it
  3. (to be continued)

Hopes this is helpful.

Geen opmerkingen: