Replies: 3 comments
-
Further to this I have since notice that sometimes the Docker IP's change after reboot which can cause a probem if you use 172.17.0.10 for example and it switches with another container after a reboot. However if you instead actually use 172.17.0.1 for querying all containers using their External Port instead of Internal it will route the traffic for you, so any container monitoring I suggests always using 0.1 and External Port numbers. Tested on Windows Docker Desktop and Docker on Synology works on both! :) Thanks |
Beta Was this translation helpful? Give feedback.
-
Thanks for this. You gave me the clues to get me going, but my eventual results were a little different. I had set all of my services except (of course) Portainer itself up using Portainer Stacks with Docker Compose scripts. This had resulted in most of them being in their own separate virtual networks (different second digits in the IP). I created a new Bridge network and moved them all, including Portainer itself, and Dashy, into that network so they all have the same first two digits in their IP. Now as you suggest, I use the gateway for that network with the port number of the service as the Status Check URL. So if the Service URL is: http://host.local:2180 the Status check URL would be http://172.18.0.1:2180 (my new network was on 172.18.x.x rather than your 172.17.x.x). This worked in all cases except one which required a routing. Service URL was http://host.local:3000/wetty and the Status check URL needed to be http://172.18.0.1:3000/wetty. I did not find that the network needed to be type Host, Bridge, the default, was fine. I also found it was sometimes necessary to restart the Dashy container (have a coffee while it restarts!) for changes to take effect, sometimes not. This is the Docker Compose script I use for Dashy:
Note the two 'networks:' sections: the name (in this case 'octobridge') needs to be the same for all the services. |
Beta Was this translation helpful? Give feedback.
-
I've got the same problem here and setting |
Beta Was this translation helpful? Give feedback.
-
Hi all,
I have done lots of testing with this over the last few days and the only way I can get Dashy to ping all destinations is when I have it running using HOST network instead of Bridge.
You DO NOT need to run in Privilaged mode when doing it this way!
In my case I have it installed on a Synology NAS which has several other containers running on it, including Critically a Pi-Hole container running in HOST mode with Elevated privliges, initially I could ping only devices on my LAN everything else would fail, after adjusting my NAS firewall rules and switching the ping check to use the docker container IP's (172.17.0.0/16 range) I could get it to check everything except for the Pi-Hole running in HOST mode.
Chaning my container to run in HOST mode resolved this problem and now I can successfully check 10.0.0.0/24, 172.17.0.0/16 and Critically the Pi-Hole container running in host mode.
P.S. I also highly recommend setting up Portainer which assist massively in discovering things like container IPs which you can see all in one view! :)
Another great thing about Portainer is it will let you recreate your containers whilst changing things like the Network Type which is something the Synology GUI will not let you do!
Hope this helps!
Beta Was this translation helpful? Give feedback.
All reactions