Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 17 additions & 16 deletions .github/workflows/molecule-loadbalancer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,23 @@

name: loadbalancer
on:
push:
paths:
- 'roles/haproxy/**'
- 'roles/keepalived/**'
- 'roles/bind/**'
- 'molecule/loadbalancer/**'
- 'roles/selfsigned_certs/**'
- '.github/workflows/molecule-loadbalancer.yml'
pull_request:
paths:
- 'roles/haproxy/**'
- 'roles/keepalived/**'
- 'roles/bind/**'
- 'molecule/loadbalancer/**'
- 'roles/selfsigned_certs/**'
- '.github/workflows/molecule-loadbalancer.yml'
workflow_dispatch:
# push:
# paths:
# - 'roles/haproxy/**'
# - 'roles/keepalived/**'
# - 'roles/bind/**'
# - 'molecule/loadbalancer/**'
# - 'roles/selfsigned_certs/**'
# - '.github/workflows/molecule-loadbalancer.yml'
# pull_request:
# paths:
# - 'roles/haproxy/**'
# - 'roles/keepalived/**'
# - 'roles/bind/**'
# - 'molecule/loadbalancer/**'
# - 'roles/selfsigned_certs/**'
# - '.github/workflows/molecule-loadbalancer.yml'

jobs:
build:
Expand Down
21 changes: 11 additions & 10 deletions .github/workflows/molecule-mongo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,17 @@

name: mongo
on:
push:
paths:
- 'roles/mongo/**'
- 'molecule/mongo/**'
- '.github/workflows/molecule-mongo.yml'
pull_request:
paths:
- 'roles/mongo/**'
- 'molecule/mongo/**'
- '.github/workflows/molecule-mongo.yml'
workflow_dispatch:
# push:
# paths:
# - 'roles/mongo/**'
# - 'molecule/mongo/**'
# - '.github/workflows/molecule-mongo.yml'
# pull_request:
# paths:
# - 'roles/mongo/**'
# - 'molecule/mongo/**'
# - '.github/workflows/molecule-mongo.yml'

jobs:
build:
Expand Down
12 changes: 6 additions & 6 deletions roles/haproxy/templates/haproxy_backend.cfg.j2
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#---------------------------------------------------------------------
#
backend {{ application.name }}_be
option httpchk {{ application.ha_method }} {{ application.ha_url }}
option httpchk {{ application.ha_method }} {{ application.ha_url }}
http-check send ver HTTP/1.1 hdr Host {{ application.vhost_name }}

{%if application.x_forwarded_port is defined %}
Expand All @@ -35,8 +35,8 @@
cookie HTTPSERVERID insert nocache indirect httponly secure maxidle {{ haproxy_cookie_max_idle }}

{% for server in application.servers %}
server {{ server.label }} {{ server.ip }}:{% if server.port is defined %}{{ server.port }}{% else %}{{ application.port }}{% endif %} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 100
server {{ server.label }} {{ server.ip }}:{% if server.port is defined %}{{ server.port }}{% else %}{{ application.port }}{% endif %} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 50

{% endfor %}

{% endfor %}
Expand All @@ -48,7 +48,7 @@
#---------------------------------------------------------------------
#
backend {{ application.name }}_staging_be
option httpchk {{ application.ha_method }} {{ application.ha_url }}
option httpchk {{ application.ha_method }} {{ application.ha_url }}
http-check send ver HTTP/1.1 hdr Host {{ application.vhost_name }}

{%if application.x_forwarded_port is defined %}
Expand All @@ -62,8 +62,8 @@
cookie HTTPSERVERIDSTAGING insert nocache indirect httponly secure maxidle {{ haproxy_cookie_max_idle }}

{% for server in application.stagingservers %}
server {{ server.label }} {{ server.ip }}:{{ application.port }} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 100
server {{ server.label }} {{ server.ip }}:{{ application.port }} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 50

{% endfor %}
{% endif %}
{% endfor %}