Sign inSign up

0rickyy0/geizhalsbot

By 0rickyy0

•Updated over 4 years ago

A bot to get notified about changes of the price of a Geizhals.de wishlist

Image
1

3.3K

0rickyy0/geizhalsbot repository overview

Build Status codecov Codacy Badge

⁠Python-GeizhalsBot

A bot to get notified about changes of the price of a geizhals.de⁠ wishlist on Telegram. It uses the python-telegram-bot⁠ Framework for talking to Telegram servers. To get the price of the site it uses pyquery as html parser, since there is no official API for grabbing prices.

⁠Requirements

This project requires Python >= 3.6 to run.

⁠Setup with Docker

The easiest way to get the bot up and running is via Docker. Set up a directory with a config.py file (you can find an example of it here⁠). If you want to make your logs accessible from the outside, add another volume as follows.

Just run the following command to run the bot:

docker run -d --name ghbot --restart always -v /path/to/logs/:/usr/src/bot/logs -v /path/to/config.py:/usr/src/bot/config.py geizhalsbot

Don't forget to exchange the paths mentioned above with paths to your config file and logging directory.

⁠Setup as systemd service

If you don't want to use docker but still want a comfortable way to control the bot, you can create a systemd service.

Create a new file as root in the systemd folder: /etc/systemd/system/geizhalsbot.service. An example systemd configuration can be found in this GitHub Gist⁠. Make sure to change the user and the paths accordingly.

With systemctl start geizhalsbot you can start the bot.
With systemctl status geizhalsbot the current status of the service is shown.
Using systemctl stop geizhalsbot you can stop the service,

More on systemd services can be found on the freedesktop wiki⁠.

⁠Known-Issues

  • The bot is triggered on every change - also if that change is only 0,01€. Later one should be able to set threshold values.

Tag summary

Content type

Image

Digest

Size

58.2 MB

Last updated

over 4 years ago

docker pull 0rickyy0/geizhalsbot