.\" approx: proxy server for Debian archive files .\" Copyright (C) 2011 Eric C. Cooper .\" Released under the GNU General Public License .\" -*- nroff -*- .TH APPROX 8 "May 2011" .\" Please adjust this date whenever revising the manpage. .SH NAME approx \- proxy server for Debian archive files .SH SYNOPSIS .PP .B approx [\fIOPTION\fP]... .SH DESCRIPTION .B approx responds to HTTP requests made by .BR apt\-get (8). It maintains a cache of Debian archive files that have been previously downloaded, so that it can respond with a local copy when possible. If a file not in the cache is requested, .B approx will download it from a remote Debian repository and deliver the contents to the client, simultaneously caching it for future use. Over time, the .B approx server cache will grow to contain multiple, unneeded versions of Debian packages. The .BR approx-gc (8) program removes these from the cache. .SH OPTIONS .TP .BR \-c " file, " \-\^\-config " file" Specify an additional configuration file. May be used multiple times. .SH USAGE .PP .B approx is invoked by .BR inetd (8). .SH EXAMPLES .PP Suppose that a client machine's .I /etc/apt/sources.list file contains the following lines: .IP deb http://apt:9999/debian testing main .br deb http://apt:9999/security testing/updates main .br deb-src http://apt:9999/debian unstable main .PP In this example, .I apt is the hostname of the .B approx server machine on the local network. Each distribution, such as "debian" or "security", is mapped to a remote repository in the .B approx server's configuration file. .PP For example, the .I approx.conf file on the .B approx server might contain the lines .IP debian http://ftp.debian.org/debian .br security http://security.debian.org .PP The mapping scheme is very simple. If the .I approx.conf file contains the line .IP repository http://remote-host/initial/path .PP then any request to the .B approx server of the form .IP http://approx-server/repository/rest/of/URL .PP is rewritten to .IP http://remote-host/initial/path/rest/of/URL .PP when there is a "cache miss", and that file is cached as .IP /var/cache/approx/repository/rest/of/URL .PP (Note that the repository name on the left-hand side is not included in the rewritten URL unless it is explicitly mentioned in the right-hand side's initial path.) .SH FILES .TP .I /etc/approx/approx.conf .br Configuration file for .B approx and related programs. .TP .I /var/cache/approx .br Default cache directory for archive files. .SH SEE ALSO .IR approx.conf (5), .BR inetd (8), .BR approx-import (8), .BR approx-gc (8), .BR apt-get (8), .IR sources.list (5) .SH AUTHOR Eric Cooper