17
avr
0

Controlling Your Linux Server Using Twitter

Last weekend I wrote about « Using Twitter To Monitor Your Linux Server » using a Released [Bash Script To Access Dropbox Via Command Line] » href= »http://www.adminreseau.fr/dropbox-uploader-0-12-released-bash-script-to-access-dropbox-via-command-line/ »>command line client « MYST« . I have added a new feature to MYST using which you can tell your server to execute commands by using DMs. Let us start configuration for the same.

Step 1: Ensure that you can Easily Send Files To Other Machines On The Local Network [Linux, Windows] » href= »http://www.adminreseau.fr/nitroshare-easily-send-files-to-other-machines-on-the-local-network-linux-windows/ »>send direct messages to your server‘s twitter account. Just follow the server‘s account and your server‘s account also needs to follow you.

Step 2: Add the following in your .myst.conf file below MYST section:

[Users]
auth_users: adityapatawari 

You can add more twitter handles separated by blank space. 

Step 3: Now you can DM any command to your server‘s account and it’ll be executed. You need to ensure that myst.py script‘s « getdm » option is in cron.

MYST uses python’s os.system to execute these commands. The user’s access level who executed myst.py will decide if the commands coming from DM will be executed or not. If you want everything to be executed then run myst.py with super user or using sudo.

Please contribute to the MYST project on Gitorious.org

Looking For The Source Code Of Life, LINUX and MORE…

Enjoyed reading this post?
Subscribe to the RSS feed and have all new posts delivered straight to you.
Post your comment




Celadon theme by the Themes Boutique