My config.yaml
#config:
# packageproxy:
# repos: [[ubuntu,http://archive.ubuntu.com/ubuntu],[partner,http://archive.canonical.com/ubuntu]]
# interval: 60
# max_rate: unlimited
# max_redirects: 5
# pdiffs: false
# offline: false
# max_wait: 10
# verbose: false
# debug: false
# port: 9999
# fetch Packages direct from the servers.
wget http://archive.ubuntu.com/ubuntu/dists/devel/main/binary-amd64/Packages.gz -O Packages-archive
wget http://archive.canonical.com/ubuntu/dists/devel/partner/binary-amd64/Packages.gz -O Packages-partner
# fetch from approx directly, as if we had modified sources.list
# first the main archive, no problem:
wget http://localhost:9999/ubuntu/dists/devel/main/binary-amd64/Packages.gz -O Packages-archive-cache-direct
# now the partner repo:
wget http://localhost:9999/ubuntu/dists/devel/partner/binary-amd64/Packages.gz -O Packages-partner-cache-direct
# oops, that 404'd. We need to change the URL like this:
wget http://localhost:9999/partner/dists/devel/partner/binary-amd64/Packages.gz -O Packages-partner-cache-direct
# Now here is the problem. Approx makes the following claim:
# "Approx also simplifies the administration of client machines: repository locations need only be changed in approx's configuration file, not in every client's /etc/apt/sources.list file."
# "Approx can be used as a replacement for apt-proxy, with no need to modify clients' /etc/apt/sources.list files"
# apr-proxy works by setting a http_proxy for apt so let's try it:
# this works
http_proxy=http://localhost:9999 wget http://archive.ubuntu.com/ubuntu/dists/devel/main/binary-amd64/Packages.gz -O Packages-archive-cache-indirect
# this fails with 404.
http_proxy=http://localhost:9999 wget http://archive.canonical.com/ubuntu/dists/devel/partner/binary-amd64/Packages.gz -O Packages-partner-cache-indirect