redirects for edu and canvas for .org
parent
036ecb5689
commit
dd97c840b6
|
@ -9,40 +9,6 @@ server {
|
||||||
root /opt/canvas/public;
|
root /opt/canvas/public;
|
||||||
index index.html;
|
index index.html;
|
||||||
|
|
||||||
passenger_enabled on;
|
return 307 https://canvas.libraryofcode.org$request_uri;
|
||||||
passenger_app_env production;
|
|
||||||
passenger_ruby /usr/local/bin/ruby;
|
|
||||||
passenger_user canvas;
|
|
||||||
passenger_group root;
|
|
||||||
passenger_friendly_error_pages on;
|
|
||||||
# passenger_root /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini;
|
|
||||||
|
|
||||||
#passenger_pool_idle_time 300;
|
|
||||||
#passenger_max_pool_size 10;
|
|
||||||
|
|
||||||
client_max_body_size 50M;
|
|
||||||
|
|
||||||
|
|
||||||
location / {
|
|
||||||
try_files $uri @app;
|
|
||||||
}
|
|
||||||
|
|
||||||
location @app {
|
|
||||||
passenger_enabled on;
|
|
||||||
}
|
|
||||||
|
|
||||||
location /assets/ {
|
|
||||||
expires max;
|
|
||||||
add_header Cache-Control public;
|
|
||||||
}
|
|
||||||
|
|
||||||
location ~* \.(?:ico|css|js|gif|jpe?g|png|woff2?|eot|ttf|svg|otf)$ {
|
|
||||||
expires max;
|
|
||||||
add_header Cache-Control public;
|
|
||||||
}
|
|
||||||
|
|
||||||
location /health_check {
|
|
||||||
access_log off;
|
|
||||||
return 200 "OK\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,48 @@
|
||||||
|
server {
|
||||||
|
listen 443 ssl http2;
|
||||||
|
listen [::]:443 ssl http2;
|
||||||
|
server_name canvas.libraryofcode.org;
|
||||||
|
|
||||||
|
ssl_certificate /etc/letsencrypt/live/libraryofcode.org/fullchain.pem;
|
||||||
|
ssl_certificate_key /etc/letsencrypt/live/libraryofcode.org/privkey.pem;
|
||||||
|
|
||||||
|
root /opt/canvas/public;
|
||||||
|
index index.html;
|
||||||
|
|
||||||
|
passenger_enabled on;
|
||||||
|
passenger_app_env production;
|
||||||
|
passenger_ruby /usr/local/bin/ruby;
|
||||||
|
passenger_user canvas;
|
||||||
|
passenger_group root;
|
||||||
|
passenger_friendly_error_pages on;
|
||||||
|
# passenger_root /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini;
|
||||||
|
|
||||||
|
#passenger_pool_idle_time 300;
|
||||||
|
#passenger_max_pool_size 10;
|
||||||
|
|
||||||
|
client_max_body_size 50M;
|
||||||
|
|
||||||
|
|
||||||
|
location / {
|
||||||
|
try_files $uri @app;
|
||||||
|
}
|
||||||
|
|
||||||
|
location @app {
|
||||||
|
passenger_enabled on;
|
||||||
|
}
|
||||||
|
|
||||||
|
location /assets/ {
|
||||||
|
expires max;
|
||||||
|
add_header Cache-Control public;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ~* \.(?:ico|css|js|gif|jpe?g|png|woff2?|eot|ttf|svg|otf)$ {
|
||||||
|
expires max;
|
||||||
|
add_header Cache-Control public;
|
||||||
|
}
|
||||||
|
|
||||||
|
location /health_check {
|
||||||
|
access_log off;
|
||||||
|
return 200 "OK\n";
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue