diff options
author | Quentin Dufour <quentin@deuxfleurs.fr> | 2021-02-01 12:42:29 +0100 |
---|---|---|
committer | Quentin Dufour <quentin@deuxfleurs.fr> | 2021-02-01 12:42:29 +0100 |
commit | 5fb05f0b7ea4dfd12fd1bbc077bb6d6a972fa480 (patch) | |
tree | 2224399ead3064570726566f2296c489388e4d68 | |
parent | 5babe6fad15b5549788cb9f872da7a9565116101 (diff) | |
download | infrastructure-5fb05f0b7ea4dfd12fd1bbc077bb6d6a972fa480.tar.gz infrastructure-5fb05f0b7ea4dfd12fd1bbc077bb6d6a972fa480.zip |
Add CORS for our load testing frontend
-rw-r--r-- | app/jitsi/config/nginx.conf | 4 | ||||
-rw-r--r-- | app/jitsi/deploy/jitsi.hcl | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/app/jitsi/config/nginx.conf b/app/jitsi/config/nginx.conf index 2795644..12cca4a 100644 --- a/app/jitsi/config/nginx.conf +++ b/app/jitsi/config/nginx.conf @@ -32,6 +32,10 @@ http { } location /http-bind { + # We add CORS to use a different frontend which is useful for load testing as we do not want to advertise too much our URL + add_header 'Access-Control-Allow-Headers' 'content-type'; + add_header 'Access-Control-Allow-Methods' 'GET,POST,PUT,DELETE,OPTIONS'; + add_header 'Access-Control-Allow-Origin' '*'; proxy_pass http://{{ env "NOMAD_ADDR_bosh_port" }}/http-bind; proxy_set_header X-Forwarded-For \$remote_addr; proxy_set_header Host \$http_host; diff --git a/app/jitsi/deploy/jitsi.hcl b/app/jitsi/deploy/jitsi.hcl index e65cb6d..1b63ab3 100644 --- a/app/jitsi/deploy/jitsi.hcl +++ b/app/jitsi/deploy/jitsi.hcl @@ -140,8 +140,8 @@ EOF tags = [ "jitsi", "traefik.enable=true", - "traefik.frontend.entryPoints=https,http", - "traefik.frontend.rule=Host:jitsi.deuxfleurs.fr;PathPrefix:/", + "traefik.frontend.entryPoints=https", + "traefik.frontend.rule=Host:jitsi.deuxfleurs.fr,visio.load-test.deuxfleurs.org;PathPrefix:/", "traefik.protocol=https" ] port = "https_port" |