Python app to launch sshd server from Telegram
Project description
SSH Telegram Manager
SSH Telegram Manager is a Telegram bot to launch ssh on demand. With this tool, you can avoid to expose your ssh port permanently on Internet.
Installation
Gentoo
If you use Gentoo, you can find the ebuild in https://github.com/turulomio/myportage/tree/master/app-admin/ssh_telegram_manager
- Get your Telegram Bot token. This is a way to get it https://www.siteguarding.com/en/how-to-get-telegram-bot-api-token
- Copy
/etc/ssh_telegram_manager/ssh_telegram_manager.default
to your/etc/ssh_telegram_manager/ssh_telegram_manager
and edit your settings. - Just run
ssh_telegram_manager
. You can use/etc/init.d/ssh_telegram_manager
to launch daemon orrc-update add ssh_telegram_manager
to launch it on server start up - When ssh_telegram_manager is working fine, disable sshd daemon from start with
rc-update del sshd
to hide your ssh port on Internet - You must use \ssh_start to launch ssh on your Telegram Bot. After 1 minute(you can change in settings) it will be closed.
Debian
If you use Debian, you can use pip pip install ssh_telegram_manager
- Get your Telegram Bot token. This is a way to get it https://www.siteguarding.com/en/how-to-get-telegram-bot-api-token
- Copy https://github.com/turulomio/ssh_telegram_manager/blob/main/etc/ssh_telegram_manager/ssh_telegram_manager.default to your /etc/ssh_telegram_manager/ssh_telegram_manager
- Edit this file to set
systemctl start ssh
andsystemctl stop ssh
as your start and stop command - Copy https://github.com/turulomio/ssh_telegram_manager/blob/main/etc/systemd/debian/ssh_telegram_manager.service to your /lib/systemd/system/ directory
- Just run ssh_telegram_manager. You can launch daemon with
systemctl start ssh_telegram_manager
. You can launch it on server start withsystemctl enable ssh_telegram_manager
- When ssh_telegram_manager is working fine, disable ssh daemon from start with
systemctl disable ssh
to hide your ssh port on Internet - You must use \ssh_start to launch ssh on your Telegram Bot. After 1 minute(you can change in settings) it will be closed.
Changelog
0.6.0
- Migrated setup.py to pyproject.toml with poetry.
0.5.0
- Upgraded code to python-telegram-bot-20.0 api
0.4.0 (2022-10-22)
- Fixed bug when system time is not set correctly
- Added
ssh_telegram_manager.service
for systemd systems - Improved spanish translation
0.3.0 (2022-08-17)
- Now waits for Internet before connecting to Telegram to avoid errors
0.1.1 (2022-08-13)
- Basic functionality
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ssh_telegram_manager-0.6.0.tar.gz
(24.0 kB
view hashes)
Built Distribution
Close
Hashes for ssh_telegram_manager-0.6.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0ed10e9d8071e73e58247941803ea8029756e78b58fe1f9d2a83951d7743be8e |
|
MD5 | cedd15a93ffd490aadb3161102aaacf5 |
|
BLAKE2b-256 | a9b5eeb2524332cbf78252f4cb7f13ee9ab2a646c98b5c28a71f517da3fccfa1 |
Close
Hashes for ssh_telegram_manager-0.6.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27859d87b073879466917d8473d3901ce1dfe4c92caa8b3d8e4de05f02b3a711 |
|
MD5 | b5034f2e79324dcf912c8c5e285aad67 |
|
BLAKE2b-256 | c911fdbd81a9c22e2547f948d14403c7afc6cc993e2651d9cd12c2c0ebdcb3d4 |