Telegram bot for eco-related information, built with Rust using Teloxide and SurrealDB.
- Telegram bot interface
- SurrealDB backend for data storage
- Docker containerization
- Automated CI/CD deployment via GitHub Actions
- Rust 1.75+ (for local development)
- Docker (for containerized deployment)
- SurrealDB instance
- Telegram Bot Token from @BotFather
- Clone the repository
- Copy
.env.exampleto.envand configure:cp .env.example .env nano .env # Add your TELOXIDE_TOKEN and SurrealDB credentials - Run locally:
cargo run
See DEPLOYMENT.md for complete production deployment instructions.
For quick Docker commands, see README_DOCKER.md.
TELOXIDE_TOKEN- Your Telegram bot tokenURL- SurrealDB host (e.g.,localhost)PORT- SurrealDB port (default:8000)DBNAME- Database nameNAMESPACE- Database namespaceUSERNAME- SurrealDB usernamePASSWORD- SurrealDB passwordRUST_LOG- Log level (default:info)
src/
├── main.rs # Entry point
├── db/ # Database operations
│ ├── mod.rs # Connection setup
│ ├── user.rs # User operations
│ └── bin_location.rs # Location operations
├── handlers/ # Bot command handlers
└── route.rs # Message routing
Automated Docker deployment via GitHub Actions. Push to main branch to automatically build and deploy to your server.
- 📖 DEPLOYMENT.md - Complete deployment setup guide
- 🐳 README_DOCKER.md - Docker command reference