I need to configure Nginx to make Goaccess work.
My environment is:
- Ubuntu 18.04 LTS
- Nginx 1.17.1 [ self-configure , path=/root ]
- Lets Encrypt
- sshfs
- goaccess [ --enable-utf8 --enable-geoip=legacy --with-openssl ]
Since this is a self-answered Q/A I'm not including my failed attempts, but instead posting my solution. Feel free to edit it or post another answer improving the current code.
This solution/configuration solved my 400 and 502 errors
nginx conf [ key point ]
goaccess [ goaccess.sh ]
sshfs [ run_sshfs.sh ]
Finally this sh for check goaccess was running or not and the mount was online or not then restart that.
check and restart [ cr.sh ]
That all. Now open your url which looks like my 'rp.test.com' you should see something similar below (if without any other special condition).
Running: