ayaports/user/rmfakecloud/rmfakecloud.nginx

42 lines
950 B
Text
Raw Normal View History

2021-06-04 15:24:22 +00:00
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name rm.example.com;
include ssl.conf;
location / {
client_max_body_size 0;
proxy_cache_bypass $http_upgrade;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Forwarded-Host $remote_addr;
proxy_set_header Host $http_host;
proxy_set_header Connection "upgrade";
proxy_pass http://127.0.0.1:3000;
}
location /token/device/new {
rewrite ^ /token/json/2/device/new;
}
location /token/user/new {
rewrite ^ /token/json/2/user/new;
}
}
server {
listen 80;
listen [::]:80;
server_name rm.example.com;
return 301 https://$host$request_uri;
}