Problem: a server behind proxy unreachable for api listening port 3050 with bedrock wordpress.
I had deployed wordpress with Trellis to my VMs. Everything is up and running perfectly. The wordpress site is accessible to the http://example.com but it won't able access through IP address like http://192.168.1.157
I had setup a node api that listening on port 3050. but when I try to browse/curl it with http://192.168.1.157:3050 or http://192.168.1.157/api
Chrome is return: This site can’t be reached ; ERR_CONNECTION_REFUSED
I only able to reach the site with http://example.com/api
I have an Nginx reverse proxy that helps me route to my Proxmox VMs.
Here are the routing rules written on my reverse proxy:
location ~* /api/ {
client_max_body_size 500M;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto http;
rewrite ^/api/(.*) /$1 break;
proxy_pass http://192.168.1.157:3050;
}
I am looking for a way, that my Trellis Wordpress can be accessed through http://192.168.1.157 . I think it will help me solve the problem.
Any advice is appreciated
Thanks