diff --git a/.drone.yml b/.drone.yml index ec4f699..cd5ea74 100644 --- a/.drone.yml +++ b/.drone.yml @@ -13,6 +13,7 @@ trigger: steps: - name: deploy-backend image: appleboy/drone-ssh + timeout: 30m settings: host: from_secret: server_host @@ -21,11 +22,12 @@ steps: password: from_secret: server_password port: 22 + command_timeout: 1800 script: - cd BetterCallPraskovia - git pull origin main - - docker-compose down backend tg_bot - - docker-compose build --no-cache backend tg_bot - - docker-compose up -d backend tg_bot - - docker image prune -a -f + - docker-compose stop backend tg_bot + - docker-compose rm -f backend tg_bot + - docker-compose up --build --force-recreate -d backend tg_bot + - docker image prune -f diff --git a/tg_bot/infrastructure/telegram/handlers/buy_handler.py b/tg_bot/infrastructure/telegram/handlers/buy_handler.py index eb7f07f..f0b910a 100644 --- a/tg_bot/infrastructure/telegram/handlers/buy_handler.py +++ b/tg_bot/infrastructure/telegram/handlers/buy_handler.py @@ -11,6 +11,7 @@ from datetime import datetime router = Router() user_service = UserService() + @router.message(Command("buy")) async def cmd_buy(message: Message): user_id = message.from_user.id