User Tools

Site Tools


linux:telegram

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
linux:telegram [2015/07/01 23:47] – [Step 6: create a daemon and install it] rlunarolinux:telegram [2015/07/02 00:13] rlunaro
Line 108: Line 108:
  
  
-===== Step 6: create a daemon and install it =====+===== Step 6: create the system user telegramd ===== 
 + 
 +In order to run the telegram-daemon as root, you will need to create the user telegramd. I've opted 
 +to create this user as a system user:  
 + 
 +<code> 
 +# useradd -M --user-group --system --shell=/bin/false telegramd 
 +</code> 
 + 
 + 
 +**And give permissions into /etc/telegram:** 
 + 
 +<code> 
 +chown telegramd:telegramd /etc/telegram/
 +</code> 
 + 
 +Impersonate this user and run the telegram-cli program again, to create a proper configuration file:  
 + 
 +<code> 
 +telegramd@:~$ /usr/local/share/telegram/telegram-cli -k /etc/telegram/tg-server.pub  
 +Telegram-cli version 1.0.5, Copyright (C) 2013-2014 Vitaly Valtman 
 +Telegram-cli comes with ABSOLUTELY NO WARRANTY; for details type `show_license'
 +This is free software, and you are welcome to redistribute it 
 +under certain conditions; type `show_license' for details. 
 +Telephone number (with '+' sign):  
 + 
 +</code> 
 + 
 + 
 + 
 +===== Step 7: create a daemon and install it =====
  
 Telegram-cli has a bug that provokes that, unless ''contact_list'' is the first command issued, no message can be sent through the program. Moreover, there is no way to create a program that just sends a message and ends: the program waits forever even if you run through a pipe. __A more simple version to make automatic notifications from a machine would be desirable.__ Telegram-cli has a bug that provokes that, unless ''contact_list'' is the first command issued, no message can be sent through the program. Moreover, there is no way to create a program that just sends a message and ends: the program waits forever even if you run through a pipe. __A more simple version to make automatic notifications from a machine would be desirable.__
Line 191: Line 221:
 </code> </code>
  
-===== Step 7: create the system user telegramd ===== 
- 
-In order to run the telegram-daemon as root, you will need to create the user telegramd. I've opted 
-to create this user as a system user:  
- 
-<code> 
-# useradd -M --user-group --system --shell=/bin/false telegramd 
-</code> 
- 
- 
-**And give permissions into /etc/telegram:** 
- 
-<code> 
-chown telegramd:telegramd /etc/telegram/* 
-</code> 
  
 ===== Step 8: install the telegram-msg program ===== ===== Step 8: install the telegram-msg program =====
linux/telegram.txt · Last modified: 2022/12/02 22:02 by 127.0.0.1