Skip to content

Latest commit

 

History

History
54 lines (34 loc) · 1.68 KB

dev.md

File metadata and controls

54 lines (34 loc) · 1.68 KB

Setup

Setup Heroku env vars according to the .env file.

# /config/routes.yaml

BoShurikTelegramBotBundle:
  resource: "@BoShurikTelegramBotBundle/Resources/config/routing.yml"
  prefix: '_telegram/%telegram_route_secret%'

Restore docker database

  1. Find name and ID
    docker ps
  2. Find the volumes
    docker inspect -f '{{ json .Mounts }}' <container_id> | python -m json.tool
  3. Copy the dump
    docker cp </path/to/dump/in/host> <container_name>:<path_to_volume>
  4. Execute psql
    docker exec <container_name> psql -U <database_owner> -d <database_name> -f <path_to_dump>
    NOTE: Use docker exec -it ... to use the psql binary from the docker container.

or better... cat backup.sql | docker exec -i 4e-website-bot_database_1 psql -U main

and using pg_restore cat backup_dbdump | docker exec -i 4e-website-bot-database-1 pg_restore -U main -d main

Google OAuth

https://hugo-soltys.com/blog/easily-implement-google-login-with-symfony-4

Telegram bots

Get updates

https://api.telegram.org/bot<YourBOTToken>/getUpdates

Update medal images and CSS

bin/console app:update:badgedata
  • Add the badge "code" in src/Service/MedalChecker.php See This commit

Emoji unicodes.

https://apps.timwhitlock.info/emoji/tables/unicode

Security