boost-proxy: copy whatever static content is available
This commit is contained in:
parent
5663ebcecf
commit
450cb58c6f
|
@ -32,10 +32,12 @@
|
|||
- haproxy
|
||||
- config
|
||||
|
||||
- name: Maintenance file is present
|
||||
- name: "Copy error pages"
|
||||
copy:
|
||||
src: "templates/haproxy/maintenance.http"
|
||||
dest: /etc/haproxy/errors/maintenance.http
|
||||
src: "templates/haproxy/static/"
|
||||
dest: "/etc/haproxy/errors/"
|
||||
owner: root
|
||||
group: root
|
||||
mode: "0644"
|
||||
notify: reload haproxy
|
||||
tags:
|
||||
|
|
|
@ -2,16 +2,13 @@
|
|||
|
||||
# HAProxy
|
||||
|
||||
- name: "Copy custom error pages for {{ site }}"
|
||||
template:
|
||||
src: "{{ template }}"
|
||||
- name: "Copy HAProxy static elements for {{ site }}"
|
||||
copy:
|
||||
src: "templates/boost-sites/{{ site }}/haproxy/static/"
|
||||
dest: "/etc/haproxy/sites/{{ site }}/"
|
||||
owner: root
|
||||
group: root
|
||||
mode: "0644"
|
||||
loop: "{{ query('fileglob', 'templates/boost-sites/{{ site }}/haproxy/*.http') }}"
|
||||
loop_control:
|
||||
loop_var: template
|
||||
tags:
|
||||
- haproxy
|
||||
- config
|
||||
|
@ -19,7 +16,7 @@
|
|||
|
||||
# Varnish
|
||||
|
||||
- name: "Copy sites custom VCL config for {{ site }}"
|
||||
- name: "Copy Varnish custom VCL for {{ site }}"
|
||||
template:
|
||||
src: "templates/boost-sites/{{ site }}/varnish/default.vcl.j2"
|
||||
dest: "/etc/varnish/sites/{{ site }}.vcl"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
acl example_domains var(req.hdr_host) -m str example.com
|
||||
acl example_domains2 var(req.hdr_host) -m str example.org www.example.org
|
||||
### acl example_maintenance_ips src -f /etc/haproxy/example/maintenance_ips
|
||||
### acl example_maintenance_ips src -f /etc/haproxy/sites/{{ site }}/maintenance_ips
|
||||
|
||||
# Redirect to HTTPS without Let's Encrypt certificate
|
||||
### http-request redirect scheme https code 301 if example_domains !{ ssl_fc }
|
||||
|
|
Loading…
Reference in a new issue