Skip to content

Latest commit

 

History

History
51 lines (40 loc) · 1.55 KB

README.md

File metadata and controls

51 lines (40 loc) · 1.55 KB

telegramInformant

Description

It helps to know what your remote resources are unavailable

Docker startup

Requirements

How to start

  1. Get project:
$ git clone https://github.com/mperov/telegramInformant.git
$ cd telegramInformant/
    1. Change file resources.json that contains all remote hosts which will being checked;
    2. Create Telegram bot;
    3. Add token of your Telegram bot in informant.py by changing variable TOKEN and add recipient by modifiying GROUP_ID.
  1. Build and run container:
$ docker-compose build
$ docker-compose up -d

If it's all right you will receive greetings message from bot.

Typical startup

Requirements

At first I recommend to create special Python virtual enviroment by

$ sudo apt-get install python3-venv -y
$ python3 -m venv telegramInformant
$ source telegramInformant/bin/activate

Next install some Python modules - pip3 install -r requirements or python3 -m pip install -r requirements
If you don't have pip3 then you may install it how described here

Usage

The first change file resources.json that contains all remote hosts which will being checked.
The second add token of your Telegram bot in informant.py by changing variable TOKEN and add recipient by modifiying GROUP_ID.
Finally

$ source telegramInformant/bin/activate
$ ./informant.py