From 10da311d832553d82be93673e7eb743b1f4c9736 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Thu, 19 Jun 2025 22:06:48 +0000 Subject: [PATCH] refine: Enhance Docker setup and docs for fork usability - Corrected 'SpeechRecognition' casing in addons/addons.txt. - Updated ultroid_setup.sh welcome message to specify the fork. - Modified README.md, README_DOCKER.md, and DOCKER_DEPLOYMENT.md: - Pointed clone/curl URLs and repository links to the overspend1/Ultroid-fork. - Reinforced ultroid_setup.sh as the primary method for Docker deployment. - Ensured documentation clarity regarding building the Docker image from the fork's source. --- DOCKER_DEPLOYMENT.md | 86 +++++++++++++++++++----------------- README.md | 14 +++--- README_DOCKER.md | 102 +++++++++++++++++++++++-------------------- addons/addons.txt | 2 +- ultroid_setup.sh | 3 +- 5 files changed, 109 insertions(+), 98 deletions(-) diff --git a/DOCKER_DEPLOYMENT.md b/DOCKER_DEPLOYMENT.md index 5f0dcd1..9c88b9c 100644 --- a/DOCKER_DEPLOYMENT.md +++ b/DOCKER_DEPLOYMENT.md @@ -1,6 +1,6 @@ -# 🐳 Ultroid Docker Deployment Guide +# 🐳 Ultroid Docker Deployment Guide (Fork: overspend1/Ultroid-fork) -Complete Docker-based deployment guide for Ultroid Telegram UserBot following the official deployment patterns. +Complete Docker-based deployment guide for this fork of Ultroid Telegram UserBot. This guide assumes you are building the Docker image from the source code of this repository. ## 📋 Prerequisites @@ -9,53 +9,57 @@ Complete Docker-based deployment guide for Ultroid Telegram UserBot following th - Session string - Basic knowledge of environment variables -## 🚀 Quick Start +## 🚀 Recommended Setup: Using `ultroid_setup.sh` -### 1. Clone Repository +The easiest and recommended way to deploy this fork using Docker is with the unified setup script: + +1. **Clone this repository:** + ```bash + git clone https://github.com/overspend1/Ultroid-fork.git + cd Ultroid-fork + ``` +2. **Run the setup script:** + ```bash + bash ultroid_setup.sh + ``` + Select the Docker setup option when prompted. The script will guide you through: + * Checking dependencies (Docker, Docker Compose). + * Configuring your `.env` file with necessary variables (API keys, session string, database choice, etc.). + * Guiding session string generation if needed. + * Building the Docker image from this fork's source. + * Starting the Docker containers. + +## Manually Deploying with Docker Compose (Advanced) + +If you prefer a manual approach: + +### 1. Clone This Repository ```bash -git clone https://github.com/TeamUltroid/Ultroid.git -cd Ultroid +git clone https://github.com/overspend1/Ultroid-fork.git +cd Ultroid-fork ``` -### 2. Generate Session String -```bash -chmod +x generate-session.sh -./generate-session.sh -``` - -Choose from multiple methods: -- **Docker** (Recommended) -- **Telegram Bot** (@SessionGeneratorBot) -- **Local Python** -- **Online Repl.it** - -### 3. Configure Environment +### 2. Configure Environment (`.env` file) +Copy the sample environment file and edit it with your details: ```bash cp .env.sample .env -nano .env +nano .env # Or your preferred editor ``` - -**Required variables:** +**Essential variables to fill:** ```env -SESSION=your_session_string -API_ID=your_api_id -API_HASH=your_api_hash -REDIS_URI=redis://redis:6379 -REDIS_PASSWORD=ultroid123 +SESSION=your_session_string_here # See README.md for generation methods +API_ID=your_api_id # From my.telegram.org/apps +API_HASH=your_api_hash # From my.telegram.org/apps +# Plus database configuration (see below or .env.sample) ``` +Refer to [Necessary Variables in the main README](../README.md#important-necessary-variables) for more details on each variable. Session string can be generated using `bash generate-session.sh` or other methods. -### 4. Deploy with Docker +### 3. Build and Deploy with Docker Compose ```bash -chmod +x docker-deploy.sh -./docker-deploy.sh +docker-compose build # Builds the Docker image from this fork's Dockerfile +docker-compose up -d # Starts the services (bot, database) in detached mode ``` - -The script will: -- ✅ Check dependencies -- ✅ Setup environment -- ✅ Configure database -- ✅ Build Docker images -- ✅ Start all services +This uses the `Dockerfile` and `docker-compose.yml` present in this repository. ## 🏗️ Architecture @@ -308,10 +312,10 @@ docker-compose up -d ## 📞 Support & Resources -- **Official Repository**: [TeamUltroid/Ultroid](https://github.com/TeamUltroid/Ultroid) -- **Telegram Support**: [@UltroidSupport](https://t.me/UltroidSupport) -- **Documentation**: [Official Docs](https://ultroid.tech) -- **Session Generator Bot**: [@SessionGeneratorBot](https://t.me/SessionGeneratorBot) +- **This Fork's Repository**: [overspend1/Ultroid-fork](https://github.com/overspend1/Ultroid-fork) +- **Original Ultroid Support (Telegram)**: [@UltroidSupport](https://t.me/UltroidSupport) (for general Ultroid questions) +- **Original Ultroid Documentation**: [Official Docs](https://ultroid.tech) (may differ for this fork) +- **Session Generator Bot**: [@SessionGeneratorBot](https://t.me/SessionGeneratorBot) (for generating session strings) ## ✨ Features Included diff --git a/README.md b/README.md index ddbac19..4cd7fff 100644 --- a/README.md +++ b/README.md @@ -28,15 +28,15 @@ The easiest way to set up Ultroid is by using our unified setup script. **Run this command in your terminal:** ```bash -bash <(curl -s https://raw.githubusercontent.com/TeamUltroid/Ultroid/main/ultroid_setup.sh) +bash <(curl -s https://raw.githubusercontent.com/overspend1/Ultroid-fork/main/ultroid_setup.sh) ``` -Or, clone the repository and run the script: +Or, clone this repository and run the script: ```bash -git clone https://github.com/TeamUltroid/Ultroid.git -cd Ultroid +git clone https://github.com/overspend1/Ultroid-fork.git +cd Ultroid-fork bash ultroid_setup.sh ``` -This script will guide you through choosing either a Docker-based or a local Python installation and help configure the necessary variables. +This script will guide you through choosing either a Docker-based or a local Python installation for this fork and help configure the necessary variables. For other deployment options or more details, see below. @@ -63,8 +63,8 @@ Get the [Necessary Variables](#Necessary-Variables) and then click the button be If you prefer a manual setup or want to understand the components: * **Docker**: Refer to [DOCKER_DEPLOYMENT.md](./DOCKER_DEPLOYMENT.md) and [README_DOCKER.md](./README_DOCKER.md). The `ultroid_setup.sh` script automates this using these Docker files. -* **Local Python**: The `ultroid_setup.sh` script automates the following general steps: - 1. Clone the repository: `git clone https://github.com/TeamUltroid/Ultroid.git && cd Ultroid` +* **Local Python**: The `ultroid_setup.sh` script automates the following general steps using this fork's code: + 1. Clone this repository: `git clone https://github.com/overspend1/Ultroid-fork.git && cd Ultroid-fork` 2. Create a Python virtual environment: `python3 -m venv .venv` 3. Activate it: `source .venv/bin/activate` 4. Install dependencies: `pip install -r requirements.txt` diff --git a/README_DOCKER.md b/README_DOCKER.md index 55b56f3..ad8bf31 100644 --- a/README_DOCKER.md +++ b/README_DOCKER.md @@ -1,19 +1,21 @@ -# 🐳 Ultroid Docker Deployment +# 🐳 Ultroid Docker Deployment (Fork: overspend1/Ultroid-fork) -Complete Docker-based deployment solution for [Ultroid Telegram UserBot](https://github.com/TeamUltroid/Ultroid) with all dependencies, databases, and services included. +Complete Docker-based deployment solution for this fork of [Ultroid Telegram UserBot](https://github.com/overspend1/Ultroid-fork) with all dependencies, databases, and services included. This guide helps you build and run a Docker image directly from this repository's source code. -## ⚡ Quick Start +## ⚡ Quick Start (Recommended) +The easiest way to set up Ultroid Docker for this fork is by using the unified setup script: ```bash -# 1. Clone repository -git clone https://github.com/TeamUltroid/Ultroid.git -cd Ultroid +# 1. Clone this repository +git clone https://github.com/overspend1/Ultroid-fork.git +cd Ultroid-fork -# 2. One-command deployment -chmod +x quick-start.sh && ./quick-start.sh +# 2. Run the setup script +bash ultroid_setup.sh ``` +Follow the prompts, and choose the Docker setup option. The script will handle `.env` configuration, session generation guidance, and Docker build/run steps. -That's it! The script will guide you through session generation and deployment. +For manual Docker commands and more details, see below. ## 🎯 What's Included @@ -34,36 +36,39 @@ That's it! The script will guide you through session generation and deployment. - **Deployment Summary** - `DEPLOYMENT_SUMMARY.md` - **Environment Template** - `.env.sample` -## 🚀 Deployment Methods +## 🚀 Manual Docker Deployment Methods -### Method 1: Quick Start (Recommended) +If you prefer not to use `ultroid_setup.sh` or want more control: + +### Method 1: Using Docker Compose (Recommended for Manual Setup) +Ensure you have an `.env` file configured (see [Configuration](#⚙️-configuration) and [Necessary Variables from Main README](../README.md#important-necessary-variables)). ```bash -./quick-start.sh -``` +# 1. Clone this repository (if not already done) +# git clone https://github.com/overspend1/Ultroid-fork.git +# cd Ultroid-fork -### Method 2: Step by Step -```bash -# Generate session -./generate-session.sh +# 2. Configure .env file with your variables +# cp .env.sample .env +# nano .env # Fill in API_ID, API_HASH, SESSION, etc. -# Configure environment -cp .env.sample .env -nano .env - -# Deploy -./docker-deploy.sh -``` - -### Method 3: Manual Commands -```bash -# Build and start -make build -make start - -# Or using docker-compose directly +# 3. Build and start containers +docker-compose build docker-compose up -d ``` +### Method 2: Using Makefile (Shortcuts for Docker Compose) +The `Makefile` provides convenient shortcuts for Docker Compose commands. +```bash +# Configure .env file first + +make build # Build the Docker image +make start # Start services (equivalent to docker-compose up -d) +# make logs, make stop, etc. are also available. See Makefile. +``` + +### Older Scripts (Deprecated) +The `quick-start.sh` and `docker-deploy.sh` scripts are now superseded by `ultroid_setup.sh`. While they might still work, using `ultroid_setup.sh` or manual `docker-compose` commands is recommended. + ## 📋 Prerequisites - Docker & Docker Compose @@ -264,25 +269,26 @@ docker-compose restart redis ## 📞 Support & Resources -- **Repository**: [TeamUltroid/Ultroid](https://github.com/TeamUltroid/Ultroid) -- **Telegram**: [@UltroidSupport](https://t.me/UltroidSupport) +- **This Fork's Repository**: [overspend1/Ultroid-fork](https://github.com/overspend1/Ultroid-fork) +- **Original Ultroid Support (Telegram)**: [@UltroidSupport](https://t.me/UltroidSupport) (for general Ultroid questions) - **Session Bot**: [@SessionGeneratorBot](https://t.me/SessionGeneratorBot) -- **Documentation**: [Official Docs](https://ultroid.tech) +- **Original Ultroid Documentation**: [Official Docs](https://ultroid.tech) (may differ from this fork) ## 📄 Files Overview +This repository contains: ``` -📁 Ultroid/ -├── 🐳 docker-compose.yml # Service orchestration -├── 🐳 Dockerfile # Container definition -├── 🚀 quick-start.sh # One-command deployment -├── 🚀 docker-deploy.sh # Advanced deployment -├── 🔑 generate-session.sh # Session generator -├── ⚙️ .env.sample # Environment template -├── 📖 DOCKER_DEPLOYMENT.md # Complete guide -├── 📋 DEPLOYMENT_SUMMARY.md # Summary -├── 🔧 Makefile # Easy commands -└── 📚 README_DOCKER.md # This file +📁 Ultroid-fork/ +├── 🚀 ultroid_setup.sh # Recommended unified setup script +├── 🐳 Dockerfile # Defines how your fork's Docker image is built +├── 🐳 docker-compose.yml # Orchestrates Docker services (bot, db) +├── 🔑 generate-session.sh # Standalone session string generator utility +├── ⚙️ .env.sample # Template for environment variables +├── 📖 README.md # Main README for this fork +├── 📖 README_DOCKER.md # This file - Docker specific guide for the fork +├── 📖 DOCKER_DEPLOYMENT.md # Detailed Docker deployment steps +├── 🔧 Makefile # Shortcuts for common commands +└── ... (rest of the bot code and resources) ``` ## 🎉 Success Indicators @@ -297,6 +303,6 @@ Your deployment is successful when: --- -**🚀 Ready to deploy Ultroid with Docker!** +**🚀 Ready to deploy your Ultroid fork with Docker!** -Start with `./quick-start.sh` for the easiest experience. +Use `bash ultroid_setup.sh` for the guided experience. diff --git a/addons/addons.txt b/addons/addons.txt index 7f2f21f..274420d 100644 --- a/addons/addons.txt +++ b/addons/addons.txt @@ -12,7 +12,7 @@ pygments pyjokes quotefancy shazamio -speechrecognition +SpeechRecognition # Corrected case speedtest-cli textblob wikipedia diff --git a/ultroid_setup.sh b/ultroid_setup.sh index 676a08f..8e39c39 100644 --- a/ultroid_setup.sh +++ b/ultroid_setup.sh @@ -268,7 +268,8 @@ _collect_env_variables() { # --- Main Script Logic --- main() { _print_msg header "Welcome to the Ultroid UserBot Setup Script!" - echo "This script will guide you through setting up Ultroid either using Docker or a local Python environment." + _print_msg info "This script will guide you through setting up your fork of Ultroid (github.com/overspend1/Ultroid-fork)." + echo "You can choose to set it up using Docker or a local Python environment." echo "-----------------------------------------------------" # Ensure script is run from project root or can find its files