Adding staging and discovery to web app.

This commit is contained in:
Samuel Clay 2021-03-15 13:55:36 -04:00
parent 4d9176872b
commit b44cc5c509
3 changed files with 13 additions and 2 deletions

View file

@ -19,9 +19,18 @@
- name: Template haproxy.cfg file
template:
src: /srv/newsblur/docker/haproxy/haproxy.consul.cfg.j2
src: "/srv/newsblur/docker/haproxy/haproxy.consul.cfg.j2"
dest: /srv/newsblur/docker/haproxy/haproxy.consul.cfg
notify: reload haproxy
when: disable_consul_services is not defined
register: updated_config
- name: Copy staging haproxy.cfg file
copy:
src: /srv/newsblur/docker/haproxy/haproxy.staging.cfg
dest: /srv/newsblur/docker/haproxy/haproxy.consul.cfg
notify: reload haproxy
when: disable_consul_services is defined
register: updated_config
- name: Start HAProxy docker container

View file

@ -70,6 +70,8 @@ ALLOWED_SUBDOMAINS = [
'dev',
'www',
'beta',
'staging',
'discovery',
'debug',
'debug3',
'nb',

View file

@ -33,7 +33,7 @@ defaults
frontend public
bind :80
bind :443 ssl crt /srv/newsblur/config/certificates/localhost.pem #ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES128-SHA:AES256-SHA256:AES256-SHA no-sslv3
rspadd Strict-Transport-Security:\ max-age=0;\ includeSubDomains
http-response add-header Strict-Transport-Security max-age=0;\ includeSubDomains
option http-server-close
# Redirect all HTTP traffic to HTTPS