dtgbot - Domoticz TeleGram BOT
Moderator: leecollings
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
There clearly is an issue with the index of the room it is trying to retrieve the devices for. The idx field should be a number in stead of a name.
Could you post (or PM) the result of the json : http://192.168.1.XXX:8080/json.htm?type ... &used=true
Is "Planta Baja" a name of a room?
Jos
Could you post (or PM) the result of the json : http://192.168.1.XXX:8080/json.htm?type ... &used=true
Is "Planta Baja" a name of a room?
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 41
- Joined: Monday 19 October 2015 12:15
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.9700
- Location: Spain
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Hi!jvdz wrote:There clearly is an issue with the index of the room it is trying to retrieve the devices for. The idx field should be a number in stead of a name.
Could you post (or PM) the result of the json : http://192.168.1.XXX:8080/json.htm?type ... &used=true
Is "Planta Baja" a name of a room?
Jos
Thank you jvdz! PM send.
"Planta Baja" is a floor name not a room. It means low level in spanish.
I'm really very grateful jvdz.
Editing...
After jvdz help i got a new error in the dtb.log....
- Spoiler: show
Solved
Guys it may sound obvious, but do not use spaces in domoticz objects names.
Thnx to jvdz for the help. You are Jedi Master
Greetings from spain.
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Hi I just don't have any luck getting dtgbot stating. I dont use any password on Domoticz.
This is the error I am getting:
Here is the details from Domoticz:
This is the error I am getting:
Code: Select all
/usr/bin/lua5.2: /home/pi/dtgbot//dtg_domoticz.lua:125: attempt to get length of global 'result' (a nil value)
stack traceback:
/home/pi/dtgbot//dtg_domoticz.lua:125: in function 'device_list_names_idxs'
/home/pi/dtgbot/dtgbot.lua:174: in function 'dtgbot_initialise'
/home/pi/dtgbot/dtgbot.lua:229: in main chunk
[C]: in ?
Code: Select all
{
result: [
{
LastUpdate: "2015-11-16 16:33:29",
Name: "TelegramBotOffset",
Type: "0",
Value: "1",
idx: "1"
},
{
LastUpdate: "2015-11-16 16:33:58",
Name: "TelegramBotMenu",
Type: "2",
Value: "Off",
idx: "2"
},
{
LastUpdate: "2015-11-16 16:34:34",
Name: "TelegramBotWhiteListedIDs",
Type: "2",
Value: "xxxxxxx",
idx: "3"
}
],
status: "OK",
title: "GetUserVariables"
Code: Select all
{
result: [
{
Devices: 16,
Name: "Main",
Order: "1",
idx: "2"
},
{
Devices: 4,
Name: "Study",
Order: "3",
idx: "3"
}
],
status: "OK",
title: "Plans"
}
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
You probably do not have any Scenes defined yet in Domoticz and the Function is "complaining" about that.
Please edit your dtg_domoticz.lua and update the below function with this version which should skip in case no Scenes are available:
Thanks
Jos
Please edit your dtg_domoticz.lua and update the below function with this version which should skip in case no Scenes are available:
Code: Select all
-- returns a list of Domoticz items based on type i.e. devices or scenes
function device_list_names_idxs(DeviceType)
--returns a devcie idx based on its name
local idx, k, record, decoded_response
decoded_response = device_list(DeviceType)
result = decoded_response['result']
devices = {}
devicesproperties = {}
if result ~= nil then
for i = 1, #result do
record = result[i]
if type(record) == "table" then
if DeviceType == "plans" then
devices[record['Name']] = record['idx']
else
devices[string.lower(record['Name'])] = record['idx']
devices[record['idx']] = record['Name']
if DeviceType == 'scenes' then
devicesproperties[record['idx']] = {Type=record['Type'], SwitchType = record['Type']}
end
end
end
end
end
return devices, devicesproperties
end
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Thanks jvdz once I create my scenes dtgbot started.
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
I now have the bot up and running. When I type a command like "help" in from the telegram I don't get a response back from the bot. Why will that be?
Code: Select all
6 - Starting Telegram api Bot message handler
2015-11-17 17:47:46 - -----------------------------------------
2015-11-17 17:47:47 - Domoticz returned getuservariables after 2 attempts
2015-11-17 17:47:47 - dtgbotLogLevel set to: 0
2015-11-17 17:47:47 - Loading command modules...
2015-11-17 17:47:47 - Loading module <utility>
2015-11-17 17:47:48 - found command <refresh>
2015-11-17 17:47:48 - Loading module <dtgmenu>
2015-11-17 17:47:48 - define LastCommand
2015-11-17 17:47:48 - found command <dtgmenu>
2015-11-17 17:47:48 - Loading module <list>
2015-11-17 17:47:48 - found command <list>
2015-11-17 17:47:48 - found command <dump>
2015-11-17 17:47:48 - Loading module <devices>
2015-11-17 17:47:48 - found command <devices>
2015-11-17 17:47:48 - found command <scenes>
2015-11-17 17:47:48 - Loading module <flick>
2015-11-17 17:47:48 - found command <flick>
2015-11-17 17:47:48 - Loading module <nflick>
2015-11-17 17:47:48 - found command <nflick>
2015-11-17 17:47:48 - Loading module <on>
2015-11-17 17:47:48 - found command <off>
2015-11-17 17:47:48 - found command <on>
2015-11-17 17:47:48 - Loading module <battery>
2015-11-17 17:47:48 - found command <batteries>
2015-11-17 17:47:48 - found command <battery>
2015-11-17 17:47:48 - Loading module <help>
2015-11-17 17:47:48 - found command <start>
2015-11-17 17:47:48 - found command <help>
2015-11-17 17:47:48 - Loading module <temperature>
2015-11-17 17:47:48 - found command <temperatures>
2015-11-17 17:47:48 - found command <tempall>
2015-11-17 17:47:48 - found command <temperature>
2015-11-17 17:47:48 - Decoded Off
2015-11-17 17:47:48 - TelegramBotWhiteListedIDs user variable does not exist in Domoticz
2015-11-17 17:47:48 - So will allow any id to use the bot
2015-11-17 17:47:48 - dtgbotLogLevel set to: 0
2015-11-17 17:47:48 - TelegramBotWhiteListedIDs user variable does not exist in Domoticz
2015-11-17 17:47:48 - So will allow any id to use the bot
2015-11-17 17:47:48 - Getting TelegramBotOffset the previous Telegram bot message offset from Domo ticz
2015-11-17 17:47:48 - Decoded 1
-
- Posts: 329
- Joined: Tuesday 16 July 2013 22:54
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 3.8807
- Location: North East England
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Try a slash infront of help - /help - should then get a response.fhwessels wrote:I now have the bot up and running. When I type a command like "help" in from the telegram I don't get a response back from the bot. Why will that be?
Check out the Telegram generic pages, they document things like this behaviour.
Raspberry Pi 2 B - 2A@5V PSU - Raspbian + Domoticz + RFXtrx(89), LightwaveRF House(dimmers, sockets, wireless/mood switches), Owl CM113, 4 LaCross Temp / Humidity Sensors, 4 Siemens PIR, Smappee, Solaredge, ESP8266
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
hi I did try the /help as well and still don't get the response. Here is the info from the getUpdate log
Code: Select all
{
update_id: 121932669,
message: {
message_id: 201,
from: {
id: xxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels"
},
chat: {
id: xxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels",
type: "private"
},
date: 1447786998,
text: "/help"
}
}
]
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Can you show me the dtb.log with the details about processing this message?
Jos
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
hi here is my dtb.log. where will I get the process message?
Code: Select all
2015-11-18 15:17:09 - DomoticzIP: 127.0.0.1
2015-11-18 15:17:09 - DomoticzPort: 8080
2015-11-18 15:17:09 - BotHomePath: /home/pi/dtgbot/
2015-11-18 15:17:09 - BotLuaScriptPath: /home/pi/dtgbot/lua/
2015-11-18 15:17:09 - BotBashScriptPath: /home/pi/dtgbot/bash/
2015-11-18 15:17:09 - TelegramBotToken: xxxxxxxxxxxxxxxxxxxI
2015-11-18 15:17:09 - TelegramBotOffset: TelegramBotOffset
2015-11-18 15:17:09 - -----------------------------------------
2015-11-18 15:17:09 - Starting Telegram api Bot message handler
2015-11-18 15:17:09 - -----------------------------------------
2015-11-18 15:17:10 - Domoticz returned getuservariables after 2 attempts
2015-11-18 15:17:11 - dtgbotLogLevel set to: 0
2015-11-18 15:17:11 - Loading command modules...
2015-11-18 15:17:11 - Loading module <utility>
2015-11-18 15:17:11 - found command <refresh>
2015-11-18 15:17:11 - Loading module <dtgmenu>
2015-11-18 15:17:11 - define LastCommand
2015-11-18 15:17:11 - found command <dtgmenu>
2015-11-18 15:17:11 - Loading module <list>
2015-11-18 15:17:11 - found command <dump>
2015-11-18 15:17:11 - found command <list>
2015-11-18 15:17:11 - Loading module <devices>
2015-11-18 15:17:11 - found command <devices>
2015-11-18 15:17:11 - found command <scenes>
2015-11-18 15:17:11 - Loading module <flick>
2015-11-18 15:17:11 - found command <flick>
2015-11-18 15:17:11 - Loading module <nflick>
2015-11-18 15:17:11 - found command <nflick>
2015-11-18 15:17:11 - Loading module <on>
2015-11-18 15:17:11 - found command <off>
2015-11-18 15:17:11 - found command <on>
2015-11-18 15:17:11 - Loading module <battery>
2015-11-18 15:17:11 - found command <batteries>
2015-11-18 15:17:11 - found command <battery>
2015-11-18 15:17:11 - Loading module <help>
2015-11-18 15:17:11 - found command <help>
2015-11-18 15:17:11 - found command <start>
2015-11-18 15:17:11 - Loading module <temperature>
2015-11-18 15:17:11 - found command <tempall>
2015-11-18 15:17:11 - found command <temperature>
2015-11-18 15:17:11 - found command <temperatures>
2015-11-18 15:17:11 - Decoded Off
2015-11-18 15:17:11 - TelegramBotWhiteListedIDs user variable does not exist in Domoticz
2015-11-18 15:17:11 - So will allow any id to use the bot
2015-11-18 15:17:11 - dtgbotLogLevel set to: 0
2015-11-18 15:17:11 - TelegramBotWhiteListedIDs user variable does not exist in Domoticz
2015-11-18 15:17:11 - So will allow any id to use the bot
2015-11-18 15:17:11 - Getting TelegramBotOffset the previous Telegram bot message offset from Domoticz
2015-11-18 15:17:11 - Decoded 1
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
When sending a text message to the BOT you defined, the dtgbot should start processing it and it will show up in the log.
I believe that the new BOTs are by default in private mode, which means only commands prefixed with a slash "/" will be send to the BOT.
https://core.telegram.org/bots look for /setprivacy
Have you followed the https://www.domoticz.com/wiki/Telegram_ ... ur_chat_id section in the WiKi?
Does that work?
Are there any errors listed in: dtb.log.errors?
You also haven't set the TelegramBotWhiteListedIDs yet, which you might want to do to ensure nobody else can send commands to your Domoticz setup.
Jos
I believe that the new BOTs are by default in private mode, which means only commands prefixed with a slash "/" will be send to the BOT.
https://core.telegram.org/bots look for /setprivacy
Have you followed the https://www.domoticz.com/wiki/Telegram_ ... ur_chat_id section in the WiKi?
Does that work?
Are there any errors listed in: dtb.log.errors?
You also haven't set the TelegramBotWhiteListedIDs yet, which you might want to do to ensure nobody else can send commands to your Domoticz setup.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
I done all of this in the wiki here is my info from the chat ID. I can also send message with curl command to the bod and that is working. There is no error dtb.log.error
Code: Select all
{
update_id: 121932675,
message: {
message_id: 215,
from: {
id: xxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels"
},
chat: {
id: xxxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels",
type: "private"
},
date: 1447856628,
text: "/help"
}
},
{
update_id: 121932676,
message: {
message_id: 216,
from: {
id: xxxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels"
},
chat: {
id: xxxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels",
type: "private"
},
date: 1447856670,
text: "/list"
}
},
{
update_id: 121932677,
message: {
message_id: 217,
from: {
id: xxxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels"
},
chat: {
id: xxxxxxxx,
first_name: "Francois",
last_name: "Wessels",
username: "fwessels",
type: "private"
},
date: 1447856732,
text: "/dump"
}
}
]
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
DTGBOT.lua should be doing the same as what you have done manually.
Can you set the Domoticz uservariable TelegramBotLoglevel to 2, restart DTGBOT, send a command to the bot and show or send me the log (after removing any private info) ?
It should contain a lot more information about what it is doing exactly at startup.
Jos
Can you set the Domoticz uservariable TelegramBotLoglevel to 2, restart DTGBOT, send a command to the bot and show or send me the log (after removing any private info) ?
It should contain a lot more information about what it is doing exactly at startup.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
here is my log.
Code: Select all
2015-11-18 18:33:03 - -----------------------------------------
2015-11-18 18:33:03 - Starting Telegram api Bot message handler
2015-11-18 18:33:03 - -----------------------------------------
2015-11-18 18:33:03 - Domoticz returned getuservariables after 1 attempts
2015-11-18 18:33:03 - Decoded 2
2015-11-18 18:33:03 - dtgbotLogLevel set to: 2
2015-11-18 18:33:03 - Loading command modules...
2015-11-18 18:33:03 - Loading module <utility>
2015-11-18 18:33:03 - found command <refresh>
2015-11-18 18:33:03 - function: 0x1f07d60
2015-11-18 18:33:03 - Loading module <dtgmenu>
2015-11-18 18:33:03 - define LastCommand
2015-11-18 18:33:03 - found command <dtgmenu>
2015-11-18 18:33:03 - function: 0x1ef0718
2015-11-18 18:33:03 - Loading module <list>
2015-11-18 18:33:03 - found command <list>
2015-11-18 18:33:03 - function: 0x1f4fe88
2015-11-18 18:33:03 - found command <dump>
2015-11-18 18:33:03 - function: 0x1f4fe88
2015-11-18 18:33:03 - Loading module <devices>
2015-11-18 18:33:03 - found command <devices>
2015-11-18 18:33:03 - function: 0x1f34ae8
2015-11-18 18:33:03 - found command <scenes>
2015-11-18 18:33:03 - function: 0x1f34ae8
2015-11-18 18:33:03 - Loading module <flick>
2015-11-18 18:33:03 - found command <flick>
2015-11-18 18:33:03 - function: 0x1f4f650
2015-11-18 18:33:03 - Loading module <nflick>
2015-11-18 18:33:03 - found command <nflick>
2015-11-18 18:33:03 - function: 0x1f50990
2015-11-18 18:33:03 - Loading module <on>
2015-11-18 18:33:03 - found command <on>
2015-11-18 18:33:03 - function: 0x1f345b8
2015-11-18 18:33:03 - found command <off>
2015-11-18 18:33:03 - function: 0x1f345b8
2015-11-18 18:33:03 - Loading module <battery>
2015-11-18 18:33:03 - found command <battery>
2015-11-18 18:33:03 - function: 0x1ef2018
2015-11-18 18:33:03 - found command <batteries>
2015-11-18 18:33:03 - function: 0x1ef2018
2015-11-18 18:33:03 - Loading module <help>
2015-11-18 18:33:03 - found command <help>
2015-11-18 18:33:03 - function: 0x1f46b68
2015-11-18 18:33:03 - found command <start>
2015-11-18 18:33:03 - function: 0x1f46b68
2015-11-18 18:33:03 - Loading module <temperature>
2015-11-18 18:33:03 - found command <tempall>
2015-11-18 18:33:03 - function: 0x1f48960
2015-11-18 18:33:03 - found command <temperature>
2015-11-18 18:33:03 - function: 0x1f48960
2015-11-18 18:33:03 - found command <temperatures>
2015-11-18 18:33:03 - function: 0x1f48960
2015-11-18 18:33:03 - JSON request <http://127.0.0.1:8080/json.htm?type=command¶m=getuservariable &idx=2>
2015-11-18 18:33:03 - Decoded Off
2015-11-18 18:33:03 - WLidx 3
2015-11-18 18:33:03 - JSON request <http://127.0.0.1:8080/json.htm?type=command¶m=getuservariable &idx=3>
2015-11-18 18:33:03 - Decoded 54005199
2015-11-18 18:33:03 - WLString: 54005199
2015-11-18 18:33:03 - Name :54005199
2015-11-18 18:33:03 - JSON request <http://127.0.0.1:8080/json.htm?type=command¶m=getuservariable &idx=4>
2015-11-18 18:33:03 - Decoded 2
2015-11-18 18:33:03 - dtgbotLogLevel set to: 2
2015-11-18 18:33:03 - WLidx 3
2015-11-18 18:33:03 - JSON request <http://127.0.0.1:8080/json.htm?type=command¶m=getuservariable &idx=3>
2015-11-18 18:33:03 - Decoded XXXXXX
2015-11-18 18:33:03 - WLString: XXXXXX
2015-11-18 18:33:03 - Name : XXXXXX
2015-11-18 18:33:03 - Getting TelegramBotOffset the previous Telegram bot message offset from Domotic z
2015-11-18 18:33:03 - TBOidx 1
2015-11-18 18:33:03 - JSON request <http://127.0.0.1:8080/json.htm?type=command¶m=getuservariable &idx=1>
2015-11-18 18:33:03 - Decoded 1
2015-11-18 18:33:03 - TBO 1
2015-11-18 18:33:03 - https://api.telegram.org/botbotXXXXXXXXX/ WHY is there 2 botbot here is it right?
pi@raspberrypi ~ $
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Did you add the bot prefix in this line in /etc/profile.d/DomoticzData.sh?WHY is there 2 botbot here is it right?
Code: Select all
export TelegramBotToken="000000000:keykeykeykeykeykeykeykey"
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 24
- Joined: Sunday 12 April 2015 9:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: latest
- Location: Johannesburg South Africa
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
yes it did when I copy it. I removed it and now it is woking. Thanks for you help
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Great to hear.
Don't forget to change the debuglevel back to 0 or else the logfile will grow pretty fast.
Enjoy
Jos
Don't forget to change the debuglevel back to 0 or else the logfile will grow pretty fast.
Enjoy
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 221
- Joined: Saturday 30 August 2014 20:20
- Target OS: Linux
- Domoticz version: 4.
- Location: Spain
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Hello
I wonder if with Telegram Remote Control is posible to get the status of devices. I just get a list of devices and I can on/off them, but I dont know if they are on or off!!!.
I mean with Remote Control, no with the new "bots system".
The info about bots I've found is not clear, and it looks like the remote control is easier for me.
Thanks
I wonder if with Telegram Remote Control is posible to get the status of devices. I just get a list of devices and I can on/off them, but I dont know if they are on or off!!!.
I mean with Remote Control, no with the new "bots system".
The info about bots I've found is not clear, and it looks like the remote control is easier for me.
Thanks
-
- Posts: 51
- Joined: Tuesday 22 April 2014 22:17
- Target OS: OS X
- Domoticz version: Beta
- Location: France
- Contact:
Re: dtgbot - Domoticz TeleGram BOT
Hello,
I've made a Dokerfile to easily build and run Telegram BOT on my Raspberry.
To build and run it
1 -Install docker
Depend of your Linux ARM distribution. For example, with Raspbian Jessie, you can fin a '.deb' file here, with last versions of docker : http://blog.hypriot.com/downloads/
2 - Build the container image
3 - Run the container with your Telegram parameters :
4 - Verify the logs to see if everything is OK
Please tell me if you like it!
I've made a Dokerfile to easily build and run Telegram BOT on my Raspberry.
To build and run it
1 -Install docker
Depend of your Linux ARM distribution. For example, with Raspbian Jessie, you can fin a '.deb' file here, with last versions of docker : http://blog.hypriot.com/downloads/
2 - Build the container image
Code: Select all
docker build -t telegrambot git://github.com/macjl/dtgbot-docker
Code: Select all
docker run -dt --restart=always --name telegrambot --env DomoticzIP=192.168.0.30 --env DomoticzPort=8080 --env TelegramBotToken="123456:ABCDEFG" --env TelegramChatId="987654321" telegrambot
Code: Select all
docker logs telegrambot
Last edited by MacJL on Monday 16 May 2016 13:40, edited 1 time in total.
Who is online
Users browsing this forum: No registered users and 1 guest