Skip to content

Hossara/vistayar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

bdd4167 · Aug 16, 2024

History

79 Commits
Jul 20, 2024
Apr 26, 2024
Mar 17, 2024
Aug 16, 2024
Jul 18, 2024
Mar 19, 2024
Jul 20, 2024
Mar 11, 2024
Apr 26, 2024
Aug 16, 2024
Jul 18, 2024
Mar 12, 2024
Jul 22, 2024
Jul 22, 2024
Jul 20, 2024
Mar 12, 2024
Apr 26, 2024

Repository files navigation

Vistayar

A node base telegram bot for vistateam academy.

Version Contributor

Tech stack: Typescript, Telegraf.js, Nodemon.js, Google firebase admin

Develop tracking

  • MVP
  • Release v1
  • Test
  • Refactor using Nest.js
  • Refactor MVP Technical debt
  • Use and implement MongoDB as main database
  • Test
  • Implement v2 backlog
  • Release v2
  • Test

Run and test

# To start redis server 
docker compose up -d

# To start app
pnpm start

Production

  1. Build and push Dockerfile into your repository
  2. Use Docker compose to run the bot
services:
  vista_redis_stack:
    container_name: vista_redis_stack
    image: redis/redis-stack:latest
    environment:
      REDIS_ARGS: "--requirepass redispass"
    ports:
      - "your_own_port:8001"
    volumes:
      - "./redis_data:/data"

  vista_bot:
    container_name: vista_bot
    image: yourusername/vistayar:latest
    restart: on-failure
    depends_on:
      - vista_redis_stack
    volumes:
      - "./db_info.json:/app/db_info.json"

! Remember to place your own db_info.json file near docker-compose.yaml

Environment

ENV Usage Required
IS_DEV To force the bot to use a proxy to connect to the server FALSE
PROXY Proxy url. For example: socks5://127.0.0.1:20170 FALSE
BOT_TOKEN Telegram bot token TRUE
REDIS_SERVER Redis server url. For example: redis://localhost:6380 TRUE
FIREBASE_ADMIN_DATABASE Google firebase admin database token TRUE

Contributors

Donate me

donate me!