-
Notifications
You must be signed in to change notification settings - Fork 11
frontends
The frontends section can be configured with the YAML tree haproxy_frontends
.
Example:
haproxy_frontends:
- name: fe-static
bind:
- 0.0.0.0:80
mode: http
maxconn: 30000
acl:
- { name: acl-is-static, condition: path_beg /static }
use_backend:
- { name: be-static, confition: if acl-is-static }
String.
String, optional.
String, optional.
List, optional.
Examples:
bind:
- 0.0.0.0:80
- 0.0.0.0:1937
Optional and only useful in conjunction to bind as it will be applied to each of its elements.
Accepts a list of mappings in the following format:
- cert: optional ;
- ciphers: optional.
String, optional.
Example:
mode: http
Numerical, optional.
Optional.
Accepts a mapping in the following format:
- param ;
- value.
Example:
timout:
- param: connect
value: 5000
Optional.
Accepts a mapping in the following format:
- name ;
- condition.
Example:
acl:
- name: acl-is-root
condition: path -i /
acl:
- { name: acl-is-root, condition: path -i / }
- { name: acl-is-static, condition: path_beg /static }
Optional.
Accepts a mapping in the following format:
- uri: string, optional ;
- fail: list, optional.
Example:
monitor:
uri: /site
fail:
- if acl-site-dead
- unless acl-localhost
List, optional.
Example:
capture:
- request header User-Agent len 64
List, optional.
List, optional.
List, optional.
List, optional.
List, optional.
List, optional.
Numerical, optional.
List, optional.
List, optional.
List, optional.
Optional.
Accepts a list of mappings in the following format:
- param ;
- value ;
- condition: optional.
Optional.
Accepts a list of mappings in the following format:
- action ;
- param: optional ;
- condition: optional.
Example:
http_request:
- { action: auth, condition: unless acl-auth }
Optional.
Accepts a list of mappings in the following format:
- action ;
- param: optional ;
- condition: optional.
String, optional.
Optional.
Accepts a list of mappings in the following format:
- name ;
- condition.
Example:
use_backend:
- { name: be-static, condition: if acl-static }
String, optional.