The-May / docker_saufbot

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This bot encourages you and your friends to drink beverages like WATER. Currently only in german, but a placeholder for english and other languages have been created.

The bot is available in https://t.me/tg_saufbot and can be triggered with /saufen

  1. Create docker-compose.yml file in your favourite directory:

#example:
version: '3'

services:
  telegram-saufbot:
    container_name: telegram_saufbot
    build:
      context: https://github.com/The-May/docker_saufbot.git
      dockerfile: Dockerfile  # Path to the Dockerfile within the repository
    environment:
      - USE_LANGUAGE=de  # Set your desired language here
      - TELEGRAM_BOT_TOKEN=a:b  # Set your Telegram bot token here
    restart: always  # Ensure the container always restarts
  1. docker-compose up --build --force-recreate
  2. if everything seems to work fine: ctrl+c out
  3. if you unintentionally exited the bot: docker start telegram_saufbot

alternatively for testing (for example in vscode):

  1. optional: set venv-> pip install -r requirements.txt -> venv\Scripts\activate
  2. install requirements.txt in venv -> pip install -r requirements.txt
  3. set env manually:
  • $env:USE_LANGUAGE="de"
  • $env:TELEGRAM_BOT_TOKEN="a:b"
  1. start saufbot.py with python

##protip: When updating, use docker builder prune --all --force before using docker-compose up --build --force-recreate

About


Languages

Language:Python 73.3%Language:Dockerfile 26.7%