Skip to content

Instantly share code, notes, and snippets.

@mgahan
Last active October 17, 2019 17:40
Show Gist options
  • Save mgahan/d95adeea0ecc9b21fb479701dc85b982 to your computer and use it in GitHub Desktop.
Save mgahan/d95adeea0ecc9b21fb479701dc85b982 to your computer and use it in GitHub Desktop.
# Server config
server {
listen 80 default_server;
listen [::]80 default_server;
root /var/www/html;
# Add index.php to the list if you are using PHP
index index.html index.htm index.nginx-debian.html;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404
try_files $uri $uri/ =404;
}
location /apps/ {
proxy_pass http://127.0.0.1:3838/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location /editor/ {
proxy_pass http://127.0.0.1:8787/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment