https://github.com/amitizle/boker-tov-nissim
Telegram bot for Boker Tov Nissim
https://github.com/amitizle/boker-tov-nissim
elixir elixir-lang otp telegram-bot
Last synced: 18 days ago
JSON representation
Telegram bot for Boker Tov Nissim
- Host: GitHub
- URL: https://github.com/amitizle/boker-tov-nissim
- Owner: amitizle
- License: mit
- Created: 2017-11-05T19:11:04.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-11-05T21:36:11.000Z (over 7 years ago)
- Last Synced: 2025-02-16T18:44:46.559Z (3 months ago)
- Topics: elixir, elixir-lang, otp, telegram-bot
- Language: Elixir
- Size: 19.5 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BokerTovNissimBot
**TODO**
Docs and README :)### Why Elixir?
Because I wanted to write a _Telegram_ bot in _Elixir_.
As a fan of Erlang/OTP, I wanted to give it a shot, it's 🔥.#### But isn't it an overkill for this kind of project?
It probably is. See _Why Elixir?_
## Building
Using the battery included `Makefile`;
```bash
$ make
```For `dev` environment, run with `MIX_ENV` environment set up to `dev`;
```bash
$ MIX_ENV=dev make
```## Release
## Running
### Using systemd
Currently the bot is running using `systemd` service, here's how it's written in my server:
```
# cat /lib/systemd/system/boker-tov-nissim.service
[Unit]
Description=Boker Tov Nissim bot[Service]
User=root
Restart=on-failure
Environment=LANG=en_US.UTF-8
Environment="WEBHOOK_URL=https://your_host.com/whatever"
Environment="TELEGRAM_BOT_TOKEN="WorkingDirectory=/opt/boker_tov_nissim
ExecStart=/opt/boker_tov_nissim/bin/boker_tov_nissim foreground
ExecStop=/opt/boker_tov_nissim/bin/boker_tov_nissim stop
PIDFile=/var/run/boker_tov_nissim.pid[Install]
WantedBy=multi-user.target
```## References
* [Telegram bot API webhooks](https://core.telegram.org/bots/webhooks)