In have the following config file for a nginx server:
server {
listen 80;
root /path/to/public;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log warn;
location / {
proxy_pass http://127.0.0.1:3000;
proxy_http_version 1.0;
proxy_redirect default;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
This works fine when I access the service using the browser or curl, but isn't working when I try to access from a POS device, the target client for this application. The device access shows up in the access.log file, but not reaches the application (built in rails) and returns http code 400. How I can debug why nginx isn't fowarding requests for the application?