From be1c844cbdbb0c8fbf68f60c7d60580e501bd485 Mon Sep 17 00:00:00 2001 From: nutra-bot Date: Fri, 21 Apr 2023 03:35:30 +0000 Subject: [PATCH] sync envs --- .editorconfig | 1 - etc/nginx/conf.d/default.conf | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.editorconfig b/.editorconfig index 26011d9..ddb84d5 100644 --- a/.editorconfig +++ b/.editorconfig @@ -12,7 +12,6 @@ max_line_length = 100 [{default,default.conf}] indent_size = 2 -indent_style = space [{nutra,*.py}] diff --git a/etc/nginx/conf.d/default.conf b/etc/nginx/conf.d/default.conf index bfab9c9..8efb6a6 100644 --- a/etc/nginx/conf.d/default.conf +++ b/etc/nginx/conf.d/default.conf @@ -15,7 +15,7 @@ server { # Sanic location / { - proxy_pass http://127.0.0.1:20000; # API server + proxy_pass http://127.0.0.1:20000; # API server # Allow fast streaming HTTP/1.1 pipes (keep-alive, unbuffered) proxy_http_version 1.1; proxy_request_buffering off; @@ -51,6 +51,7 @@ server { # React app (base URL) location / { + #return 302 https://$host/api$request_uri; root /var/www/app; index index.html; #try_files $uri $uri/ /index.html =404; @@ -78,6 +79,7 @@ server { include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot + # TODO: better redirect based on server, not if? if ($host = www.dev.nutra.tk) { return 301 https://dev.nutra.tk$request_uri; } -- 2.52.0