Skip to content

Commit

Permalink
P7A-174: proxy node domain to Next.js
Browse files Browse the repository at this point in the history
  • Loading branch information
pspanja committed Feb 26, 2025
1 parent 9f63c43 commit 6ae12f8
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
2 changes: 1 addition & 1 deletion nginx/sites-available/ez
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ server {
listen 127.0.0.1:443 ssl;
listen 127.0.0.1:80;

server_name .ez;
server_name ~.*\.ez;

include conf.d/host_resolver;

Expand Down
15 changes: 15 additions & 0 deletions nginx/sites-available/nextjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
server {
listen 127.0.0.1:80;
listen 127.0.0.1:443 ssl;

server_name ~.*\.node\..*;

location / {
proxy_pass http://127.0.0.1:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
2 changes: 1 addition & 1 deletion nginx/sites-available/sf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ server {
listen 127.0.0.1:443 ssl;
listen 127.0.0.1:80;

server_name .sf;
server_name ~.*\.sf;

include conf.d/host_resolver;

Expand Down
2 changes: 1 addition & 1 deletion nginx/sites-available/wp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ server {
listen 127.0.0.1:443 ssl;
listen 127.0.0.1:80;

server_name .wp;
server_name ~.*\.wp;

set $_install_dir _invalid_host_format;
set $_base_path /var/www;
Expand Down

0 comments on commit 6ae12f8

Please sign in to comment.