Sign inSign up

vorobalek/telegram-budget

By vorobalek

•Updated over 1 year ago

small profit-loss calculator via docker-friendly telegram bot

Image
Integration & delivery
0

1.9K

vorobalek/telegram-budget repository overview

⁠Try it out

⁠Preview

⁠Docker Compose installation

docker and docker compose required

  1. Run
    /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/vorobalek/telegram-budget/main/deployment/install-docker-compose.sh)"
    
  2. Follow the installation script instruction.

⁠Build

  1. docker build -t <image nametag> .
    
  2. docker run \
      -d \
      -e 'TELEGRAM_BOT_TOKEN=<...>' \
      -e 'TELEGRAM_WEBHOOK_SECRET=<...>' \
      -e 'DB_CONNECTION_STRING=<...>' \
      -e 'PORT=<...>' \
      -e 'DOMAIN=<...>' \ 
      -e 'AUTHORIZED_USER_IDS=<...>' \
      -e 'LOCALE=<...>' \
      -e 'DATE_FORMAT=<...>' 
      -e 'DATETIME_FORMAT=<...>' \
      -e 'SENTRY_DSN=<...>' \
      -p <machine port>:<container port> \
    --restart always \
    --name <container name> \
    <image nametag>
    

⁠Environment variables (ex. is located here⁠)

KeyDescriptionRequiredSecretDefault
TELEGRAM_BOT_TOKENTelegram Bot API token.YESYES
TELEGRAM_WEBHOOK_SECRETA secret token to be sent in a header X-Telegram-Bot-Api-Secret-Token in every webhook request, 1-256 characters. Only characters A-Z, a-z, 0-9, _ and - are allowed. The header is useful to ensure that the request comes from a webhook set by you.YESYES
DB_CONNECTION_STRINGThe connection string of the PostgreSQL database to connect to.YESYES
PORTThe number of the port for receiving requests after SSL proxy if you have.YESNO–
DOMAINThe domain to send Telegram updates to. SSL is required. The https:// prefix will be added.YESNO–
AUTHORIZED_USER_IDSA list of Telegram user IDs allowed to interact with the bot. List of numbers splitted by commas, spaces, or semicolons. Or * to authorize everyone.YESNO–
LOCALEThe locale for the text responses from the bot. Only ru and en are currently available.NONOen
DATETIME_FORMATThe format for the date and time text representation. Ex.: hh:mm tt MM/dd/yyyy or dd.MM.yyyy HH:mm.NONOhh:mm tt MM/dd/yyyy
SENTRY_DSNThe Data Source Name of a project in Sentry. Not configured by default.NOYES–

Tag summary

Content type

Image

Digest

sha256:9826ea780…

Size

111 MB

Last updated

over 1 year ago

docker pull vorobalek/telegram-budget