librenms-plugins / Weathermap

MIT License
64 stars 51 forks source link

missing "/" between server url and graph, device overlib path #36

Closed lorenzo95 closed 7 years ago

lorenzo95 commented 7 years ago

I just installed librenms on 16.04 with nginx following the instructions on http://docs.librenms.org/Installation/Installation-Ubuntu-1604-Nginx/.

After cloning this repo and following its instructions, I created a map and everything works until I try to mouse over the nodes or links. The url that it is trying to access which is the url also shown in the .conf file is missing a / between the host and the path. Example:

NODE 1
        LABEL localhost
        INFOURL http://librenms.home.localdevice/device=1/
        OVERLIBGRAPH http://librenms.home.localgraph.php?height=100&width=512&device=1&type=device_bits&legend=no
        POSITION 336 289

Should be

NODE 1
        LABEL localhost
        INFOURL http://librenms.home.local/device/device=1/
        OVERLIBGRAPH http://librenms.home.local/graph.php?height=100&width=512&device=1&type=device_bits&legend=no
        POSITION 336 289

Manually fixing it solves the issue. Haven't been able to figure out yet what is causing it. Never had this problem using it with cacti for a decade or so. Not sure if nginx is stripping too much using the given virtual server template maybe (http://docs.librenms.org/Installation/Installation-Ubuntu-1604-Nginx/)?

Everything else works great ;)

laf commented 7 years ago

We use $config['base_url'] from config.php in LibreNMS to build that, I expect you have it set to http://librenms.home.local - just add / there.