Skip to content

Commit

Permalink
fix: try fix mds1
Browse files Browse the repository at this point in the history
  • Loading branch information
dougppaz committed Apr 28, 2024
1 parent ccd4d5a commit 63d08ec
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion playbook/templates/config/haproxy.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ frontend roll
acl ACL_statics hdr(host) -i statics.{{ roll_subdomain_base }}
use_backend statics if ACL_statics
acl ACL_main hdr(host) -i {{ roll_subdomain_base }}
use_backend mds1 if { path_beg /medias/mds1 } ACL_main
use_backend mds1 if { path_beg /mds1 } ACL_main
acl ACL_prometheus hdr(host) -i prometheus.monitoring.{{ roll_subdomain_base }}
use_backend prometheus if ACL_prometheus
acl ACL_grafana hdr(host) -i grafana.monitoring.{{ roll_subdomain_base }}
Expand Down
6 changes: 3 additions & 3 deletions playbook/templates/config/nginx.medias.default.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ server {
alias /usr/share/nginx/html;
}

location / {
if ($request_uri ~* "/medias/mds(.*)/(.*)") {
proxy_pass http://app/media/$2;
location /mds1/ {
if ($request_uri ~* "/mds1/(.*)") {
proxy_pass http://app/media/$1;
proxy_set_header Host {{ roll_subdomain_base }};
proxy_buffering off;
proxy_redirect off;
Expand Down
2 changes: 1 addition & 1 deletion playbook/templates/roll.stack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ services:
SUBDOMAIN_BASE: {{ roll_subdomain_base }}
CORS_ALLOWED_ORIGIN_REGEXES: "^https://\\w+\\.{{ roll_subdomain_base }}$$,^https://{{ roll_subdomain_base }}$$"
STATIC_URL: https://statics.{{ roll_subdomain_base }}/
MEDIA_URL: https://{{ roll_subdomain_base }}/medias/mds1/
MEDIA_URL: https://{{ roll_subdomain_base }}/mds1/
CSP_CONNECT_SRC: "'self',{{ roll_subdomain_base }},*.{{ roll_subdomain_base }}"
CSP_STYLE_SRC: "'self','unsafe-inline','unsafe-hashes',{{ roll_subdomain_base }},statics.{{ roll_subdomain_base }},fonts.googleapis.com"
CSP_FONT_SRC: "'self',{{ roll_subdomain_base }},statics.{{ roll_subdomain_base }},fonts.gstatic.com"
Expand Down

0 comments on commit 63d08ec

Please sign in to comment.