roles/taiga: Fix HTTP->HTTPS redirect

The HTTP->HTTPS redirect must be defined in global scope in order for it
to work.
jenkins-master
Dustin 2019-03-22 09:26:46 -05:00
parent 7e585445b9
commit b0690f942f
1 changed files with 5 additions and 5 deletions

View File

@ -8,6 +8,11 @@ ProxyPass /admin http://localhost:8001/admin
ProxyPassReverse /admin http://localhost:8001/admin ProxyPassReverse /admin http://localhost:8001/admin
ProxyPass /events ws://localhost:8888/events ProxyPass /events ws://localhost:8888/events
RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteRule /.* https://%{SERVER_NAME}$0
Alias /static /usr/local/lib/taiga/taiga-back/static Alias /static /usr/local/lib/taiga/taiga-back/static
<Directory /usr/local/lib/taiga/taiga-back/static> <Directory /usr/local/lib/taiga/taiga-back/static>
Require all granted Require all granted
@ -22,11 +27,6 @@ DocumentRoot /usr/local/lib/taiga/taiga-front-dist/dist
<Directory /usr/local/lib/taiga/taiga-front-dist/dist> <Directory /usr/local/lib/taiga/taiga-front-dist/dist>
Require all granted Require all granted
RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteRule /.* https://%{SERVER_NAME}$0
RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.html [L] RewriteRule ^ index.html [L]