How to add datasource (influxdb) which is in another server

I am integrating nagios with grafana. I am getting data of nagios in my influxdb which is in a different server from grafana. When I give the ip of the server in the grafana datasourece it says error bad gatway.


Please try and add a / after the port.

Good Luck