File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,22 +17,22 @@ loosely based on the [ngx_http_auth_request_module] module for nginx.
1717## Usage
1818
19191 . Load this Lua script in the ` global ` section of your ` haproxy.cfg ` :
20- ```
20+ ``` haproxy
2121 global
2222 # *snip*
2323 lua-prepend-path /usr/share/haproxy/?/http.lua # If haproxy-lua-http is saved as /usr/share/haproxy/haproxy-lua-http/http.lua
2424 lua-load /usr/share/haproxy/auth-request.lua
2525 ```
2626
27272. Define a backend that is used for the subrequests:
28- ```
28+ ```haproxy
2929 backend auth_request
3030 mode http
3131 server auth_request 127.0.0.1:8080 check
3232 ```
3333
34343. Execute the subrequest in your frontend (as early as possible):
35- ```
35+ ```haproxy
3636 frontend http
3737 mode http
3838 bind :::80 v4v6
@@ -49,7 +49,7 @@ loosely based on the [ngx_http_auth_request_module] module for nginx.
4949 ```
5050
51514. Act on the results:
52- ```
52+ ```haproxy
5353 frontend http
5454 # *snip*
5555
You can’t perform that action at this time.
0 commit comments