installing Ubuntu https PPA's with squid caching

Hylton Conacher (ZR1HPC) hylton at conacher.co.za
Fri Dec 14 12:41:49 UTC 2018


Hi Stuart,

Sri for coming in late.

On 2018/11/19 07:16, Stuart McGraw wrote:
> TL;DR: How to set up apt and a squid proxy so that
> https urls are cached?
> 
> I recently tried a novel (to me) way of installing
> and configuring Ubuntu by scripting the install.
> The idea is that the script(s) provide a record of
> what and how things were installed, provide for
> disaster recovery (I backup only user files), allow
> for easier future reinstalls, and I can duplicate my
> current configuration in a VM for testing new
> software without risk of trashing my main machine.
> 
> Getting the scripts working (and maintaining changes
> going forward) requires running them dozens of times.
> 
> But... I live in third-world America and have a slow
> internet connection with a data cap.
> 
> The single thing that makes it practical to do was
> setting up a Squid caching proxy on another local
> machine and configuring Apt to use it when installing
> in order not to download GBs of packages multiple
> times.
> 
> The problem I am finding is that as I add new
> software many PPA repos use https rather than
> http for access and Squid doesn't seem cache these
> packages.  I am also concerned that Ubuntu will
> at some point switch to https which will, for me,
> kill any possibility of using scripts.
> 
> Is there some way of setting up Apt and the squid
> proxy so that it will cache https urls?


Ouch, I think we all have experienced slow Internet and data caps. Why 
not set-up your other machine as a firewall <https://www.ipfire.org> 
with an included squid caching proxy with a static 'green interface' IP? 
I know I used to use its predecessor IPCop for the same but dev work has 
stopped on IPCop.

Then it does not matter how many times you request a file from the net, 
its going to check the proxy first.

Just a thought.

Regards
Hylton




More information about the ubuntu-users mailing list