Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80 default_server;
- listen [::]:80 default_server;
- server_name sub.myserver.com;
- root /var/www/html;
- index index.html index.htm;
- location / {
- try_files $uri $uri/ =404;
- }
- }
- server {
- listen 80;
- listen [::]:80;
- server_name subapi.myserver.com;
- location / {
- proxy_pass http://localhost:1337;
- proxy_http_version 1.1;
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection keep-alive;
- proxy_set_header Host $host;
- proxy_cache_bypass $http_upgrade;
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
- proxy_set_header X-Forwarded-Proto $scheme;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement