Connecting Raspberry pi to proxy server

In this tutorial, I am going to tell you how to connect raspberry pi to the proxy server.

As most of the colleges have internet connection through local ethernet having its own proxy settings so for downloading packages on raspi you have to set up local proxy settings.

Here are the simple steps for connecting raspi to the proxy server.

  1. Open Root Terminal (Ctrl+Alt+T) and then type:

    This command creates a file named 10proxy and then add proxy settings to this file by typing:

    and save it. You need to add in the exact format as written above (do not leave any semicolon or space).
  2. Again in Root Terminal  type:

    then add proxy settings to this file by typing:

    and save it. If you want to know more about environment variables follow this link https://help.ubuntu.com/community/EnvironmentVariables
  3. Again in Root Terminal type:

    This opens bash file scroll to the end of the file and type:

    and save it. If you want to know more about .bashrc follow this link https://askubuntu.com/questions/540683/what-is-a-bashrc-file-and-what-does-it-do
  4. At last in Root Terminal type
  5. In order to download the file using sudo, update sudoers. First, open sudoers using

    Then add the following line so that sudo is able to use the above environment variables

    Reboot pi for the changes to work.
  6. Then run the following command in the Root Terminal for checking if the internet is working

Hope this helps. Enjoy!!!

6 thoughts on “Connecting Raspberry pi to proxy server

  1. Sleeth (@dansleeth)

    In bashrc you have “export https_proxy=httpS” but in 10proxy and environment you only use “http” do I need to specify httpS in the secure proxy address? (capitalisation just to make it obvious in this text) Thanks!

    Reply
  2. Juminu

    Hello, I need Help to add a Web Proxy Server in Volumio 2.587 Raspberry
    Other Tools mxxxxaudio have Proxy Options but I like to use Volumio2

    Volumio can not connect to internet for radio/update/album art etc when behind a proxy. Type of proxy that needed to set a IP address and a port,
    no username/password required. WIFI without a proxy (phone hot spot) works fine so set ups are fine.

    Question/Information needed: Volumio uses a modified version of raspbian. How does Volumio connects to net? It uses wpa_supplicant.conf for keeping wifi user name/password as in regular Raspbian. Regular Raspbian uses /etc/environment file to store proxy setting for browser connection, /etc/apt/apt.conf.d file for apt-get. So more specifically, what service Volumio uses to get album art/ internet radio etc? I tried to put proxy informtion in /etc/environment file created in Volumio, which did not work.

    I use this Guide but it won‘t help. apt-get update work.

    https://theailearner.com/2018/03/13/con … xy-server/

    Appreciate more information regarding this.

    Reply
  3. Pingback: Proxy settings for Raspbian Jessie [SOLVED] – Wanted Solution

Leave a Reply