Skip to content

Instantly share code, notes, and snippets.

@TimWolla
Last active June 22, 2018 17:06
Show Gist options
  • Select an option

  • Save TimWolla/faf20769c5ba46b6f1db79238f7cc8a7 to your computer and use it in GitHub Desktop.

Select an option

Save TimWolla/faf20769c5ba46b6f1db79238f7cc8a7 to your computer and use it in GitHub Desktop.

Revisions

  1. TimWolla revised this gist Jun 22, 2018. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -10,6 +10,7 @@ backend auth_request
    server auth_request 127.0.0.1:8080

    listen auth_request2
    mode http
    bind 127.0.0.1:8080

    server one 10.0.0.1:8080 ssl check
  2. TimWolla revised this gist Jun 22, 2018. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -12,5 +12,5 @@ backend auth_request
    listen auth_request2
    bind 127.0.0.1:8080

    server auth_request 10.0.0.1:8080 ssl check
    server auth_request 10.0.0.2:8080 ssl check
    server one 10.0.0.1:8080 ssl check
    server two 10.0.0.2:8080 ssl check
  3. TimWolla revised this gist Jun 22, 2018. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -10,7 +10,7 @@ backend auth_request
    server auth_request 127.0.0.1:8080

    listen auth_request2
    bind 127.0.0.1:80
    bind 127.0.0.1:8080

    server auth_request 10.0.0.1:8080 ssl check
    server auth_request 10.0.0.2:8080 ssl check
  4. TimWolla created this gist Jun 22, 2018.
    16 changes: 16 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,16 @@
    frontend http
    mode http
    bind :::80 v4v6

    http-request lua.auth-request auth_request /is-allowed
    http-request deny if ! { var(txn.auth_response_successful) -m bool }

    backend auth_request
    mode http
    server auth_request 127.0.0.1:8080

    listen auth_request2
    bind 127.0.0.1:80

    server auth_request 10.0.0.1:8080 ssl check
    server auth_request 10.0.0.2:8080 ssl check