Installation
Install the Update module as follows for your platform:
$ # On Debian/Ubuntu
$ sudo apt-get install hapee-1.6r1-lb-update
$ # On CentOS/RedHat/Oracle
$ sudo yum install hapee-1.6r1-lb-update
Configuration
-
In the
global
section of your configuration file, add amodule-load
directive to load the Update module:global module-load hapee-lb-update.so
-
Below the
global
section, add a new configuration section nameddynamic-update
. Inside, add one or moreupdate
lines that specify from where and how often to download new content. Here is an example that updates the contents of a file at /etc/hapee-1.6/redirects.map from the URL http://10.0.0.1:80/redirects.map:dynamic-update update id
/etc/hapee-1.6/redirects.mapmap urlhttp://10.0.0.1:80/redirects.map delay 300sAs an example, the contents of this file could be a list of IP subnets and URL paths to redirect clients to if their IP address falls within one of the ranges:
10.0.0.0/8 /maint/maintenance.html 192.168.0.0/16 /maint/forbiden.html 0.0.0.0 /maint/deny.html
In the following snippet, a
frontend
references this data using anacl
directive and anhttp-request redirect
directive:frontend fe_main mode http bind :80 acl redirect_needed src,map_ip(/etc/hapee-1.6/redirects.map) -m found http-request redirect location src,map_ip(/etc/hapee-1.6/redirects.map) if redirect_needed
Next up
TLS session ticket keys