I have managed to port emme's script bellow
to a domoticz python plugin.
Plugin updates a "General,Text" Value with your Wan IP Address. This value can be used later on in order to update any scripts or notify you upon IP change.
I hope you like it.
Find newest version GitHub:
- Make sure you have Python3 installed!
Code: Select all
sudo apt-get install python3 sudo apt-get install python3-dev
Installation from GitHub:
Code: Select all
cd plugins mkdir WAN-IP-CHECKER sudo apt-get update sudo apt-get install git git clone https://github.com/ycahome/WAN-IP-CHECKER.git WAN-IP-CHECKER cd WAN-IP-CHECKER sudo chmod +x plugin.py sudo /etc/init.d/domoticz.sh restart
Old Way Installation:
- Create Plugin Folder "WAN-IP-CHECKER" under "domoticz/plugins" folder
- Save this script as "plugin.py" on "WAN-IP-CHECKER" folder
- Restart domoticz service.
- Add a new entry of this Hardware on your domoticz installation (Setup/Hardware/select and add "Wan Ip Checker")
- NOTE:When userid/pw checking is active, make sure to add 127.0.0.* to the Local Networks field on the Settings of your Domoticz. ( many thanks to manjh for his help)
What am going to see?:
- Plugin will auto-add one Text Counter on your "Utility" Section named "<Your Hardware Name>- WAN IP 1".
1. if I enable notification, will it send an e-mail? To which mail address?
- If you enable notifications, Domoticz notification settings will be used
2. what does the field "Check My IP URL" mean?
- is the URL that returns your WAN IP
3. Does the plugin send one single notification, or repeating?
- Single notification (one for each notification option set on settings) for every WAN IP change.
4. "Check My IP URL" .What is it used for? Compare to the outside IP address? Or should I fill in a site like WhoAmI?
- You can use the default one or another. Its up to you.