blob: a4ec2d82f15eb9bc18b73a0804e7328cf3cc41c4 [file] [log] [blame]
<?xml version="1.0"?>
<!DOCTYPE modulesynopsis SYSTEM "../style/modulesynopsis.dtd">
<?xml-stylesheet type="text/xsl" href="../style/manual.en.xsl"?>
<!-- $LastChangedRevision$ -->
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<modulesynopsis metafile="mod_proxy_express.xml.meta">
<name>mod_proxy_express</name>
<description>Dynamic mass reverse proxy extension for
<module>mod_proxy</module></description>
<status>Extension</status>
<sourcefile>mod_proxy_express.c</sourcefile>
<identifier>proxy_express_module</identifier>
<summary>
<p>This module creates dynamically configured mass reverse
proxies, by mapping the Host: header of the HTTP request to
a server name and backend URL stored in a DBM file.
This allows for easy use of a huge number of reverse proxies
with no configuration changes. It is much less feature-full
than <module>mod_proxy_balancer</module>, which also provides
dynamic growth, but is intended to handle much, much
larger numbers of backends. It is ideally suited as a
front-end HTTP switch and for micro-services architectures.</p>
<p>This module <em>requires</em> the service of <module
>mod_proxy</module>.</p>
<note type="warning"><title>Warning</title>
<p>Do not enable proxying until you have <a
href="mod_proxy.html#access">secured your server</a>. Open proxy
servers are dangerous both to your network and to the Internet at
large.</p>
</note>
<note><title>Limitations</title>
<ul>
<li>This module is not intended to replace the dynamic capability of
<module>mod_proxy_balancer</module>. Instead, it is intended to be mostly
a lightweight and fast alternative to using <module>mod_rewrite</module>
with <directive>RewriteMap</directive> and the <code>[P]</code> flag
for mapped reverse proxying.
</li>
<li>It does not support regex or pattern matching at all.
</li>
<li>It emulates:
<highlight language="config">
&lt;VirtualHost *:80&gt;
ServerName front.end.server
ProxyPass "/" "back.end.server:port"
ProxyPassReverse "/" "back.end.server:port"
&lt;/VirtualHost&gt;
</highlight>
That is, the entire URL is appended to the mapped backend
URL. This is in keeping with the intent of being a simple
but fast reverse proxy switch.
</li>
</ul>
</note>
</summary>
<seealso><module>mod_proxy</module></seealso>
<directivesynopsis>
<name>ProxyExpressEnable</name>
<description>Enable the module functionality.</description>
<syntax>ProxyExpressEnable [on|off]</syntax>
<default>off</default>
<contextlist><context>server config</context><context>virtual host</context>
</contextlist>
<compatibility>Available in Apache 2.3.13 and later</compatibility>
<usage>
<p>The <directive>ProxyExpressEnable</directive> directive
controls whether the module will be active.</p>
</usage>
</directivesynopsis>
<directivesynopsis>
<name>ProxyExpressDBMFile</name>
<description>Pathname to DBM file.</description>
<syntax>ProxyExpressDBMFile &lt;pathname&gt;</syntax>
<default>None</default>
<contextlist><context>server config</context><context>virtual host</context>
</contextlist>
<compatibility>Available in Apache 2.3.13 and later</compatibility>
<usage>
<p>The <directive>ProxyExpressDBMFile</directive> directive
points to the location of the Express map DBM file. This
file serves to map the incoming server name, obtained from
the Host: header, to a backend URL.</p>
<note><title>Note</title>
<p>The file is constructed from a plain text file format using
the <code><a href="../programs/httxt2dbm.html">httxt2dbm</a></code>
utility.</p>
<example><title>ProxyExpress map file</title>
##<br />
##express-map.txt:<br />
##<br />
<br />
www1.example.com http://192.168.211.2:8080<br />
www2.example.com http://192.168.211.12:8088<br />
www3.example.com http://192.168.212.10<br />
</example>
<example><title>Create DBM file</title>
httxt2dbm -i express-map.txt -o emap<br />
</example>
<example><title>Configuration</title>
ProxyExpressEnable on<br />
ProxyExpressDBMFile emap<br />
</example>
</note>
</usage>
</directivesynopsis>
<directivesynopsis>
<name>ProxyExpressDBMType</name>
<description>DBM type of file.</description>
<syntax>ProxyExpressDBMFile &lt;type&gt;</syntax>
<default>"default"</default>
<contextlist><context>server config</context><context>virtual host</context>
</contextlist>
<compatibility>Available in Apache 2.3.13 and later</compatibility>
<usage>
<p>The <directive>ProxyExpressDBMType</directive> directive
controls the DBM type expected by the module. The default
is the default DBM type created with <code>
<a href="../programs/httxt2dbm.html">httxt2dbm</a></code>.</p>
<p>Possible values are (not all may be available at run time):</p>
<table border="1" style="zebra">
<columnspec><column width=".3"/><column width=".7"/></columnspec>
<tr><th>Value</th><th>Description</th></tr>
<tr><td><code>db</code></td><td> Berkeley DB files</td></tr>
<tr><td><code>gdbm</code></td><td> GDBM files</td></tr>
<tr><td><code>ndbm</code></td><td> NDBM files</td></tr>
<tr><td><code>sdbm</code></td><td> SDBM files (always available)</td></tr>
<tr><td><code>default</code></td><td> default DBM type</td></tr>
</table>
</usage>
</directivesynopsis>
</modulesynopsis>