Those who use Ubuntu in internet-restricted area such as college or office, probably will need proxy configuration for their apt-get command. Especially in the college, when every student given username and password for campus proxy to connect to the internet. Actually we just need to configure proxy or with/without authentication in apt.conf file. Here we go.

Assumptions

Let assume we have these credential information:

Proxy server: proxy.server.edu

Port: 443

Username: myusername@mycollege.edu

Password: mypassword

How To Configure

Open Terminal.

Perform command: sudo gedit /etc/apt/apt.conf

Type the configuration text below.

Save Gedit and exit.

Test command sudo apt-get update when you are in the proxified area.

How To Revert Configuration

Open Terminal.

Perform command: sudo gedit /etc/apt/apt.conf

Type a "#" sign without quotes in every beginning of line exactly before Acquire.