Monday, December 20, 2010

Using launchpad PPA behind proxy

I was trying to setup my Ubuntu VM in work machine and I was trying to install Chromium-daily build ppa from launchpad. I have global proxy setup in my account but when I tried to setup the PPA it was not working. So standard method

sudo apt-add-repository ppa:your-ppa


was not working. The alternative was to manually set repository and authenticate the repo via 'apt-key' as shown below:

Step 1: Add the repository via 'apt-add-repository' without authenticating its GPG key.

sudo apt-add-repository 'deb http://ppa.launchpad.net/gwibber-daily/ppa/ubuntu jaunty main'


Here replace the repository info.

Step 2: Authenticate the repository using 'apt-key'. First get the PPA key info from its web page. For Chromium-daily build the key is 4E5E17B5. Use following command to authenticate using http-proxy settings of your machine.

sudo apt-key adv --keyserver keyserver.ubuntu.com --keyserver-options http-proxy="http://your.proxy.server" --recv-keys 4E5E17B5


If things goes well then you will see a message from gpg saying 'Total number processed: 1' and you should be able to install your software from either Synaptic or Ubuntu-Software-Center.

3 comments:

  1. For some reason, this still doesn't work. I'm behind my dorm proxy and this doesn't show me any result. It just keeps working. Any ideas?

    ReplyDelete
  2. Try out following command:

    sudo gpg --keyserver keyserver.ubuntu.com --keyserver-options http-proxy="http://your.proxy.server" --recv-keys 4E5E17B5

    ReplyDelete
  3. It works like a charm. For anyone who's behind a proxy that requires authentication -> http-proxy="http://usr:pwd@address:port" e.g http-proxy="http://viktor:mysecret@192.168.1.1:80"
    Au revoir!

    ReplyDelete