From 14e6e55b3bff4d777eb7ceeca273f43b2586a6ab Mon Sep 17 00:00:00 2001 From: Khoa Vo Date: Thu, 14 May 2026 14:35:13 +0700 Subject: [PATCH] docs: restyle README with badges, icons, and visual layout --- README.md | 140 +++++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 108 insertions(+), 32 deletions(-) diff --git a/README.md b/README.md index c150557..5079a1c 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,29 @@ -# KV-Tube +

+ Go + Next.js + Docker + SQLite + License +

-A modern, self-hosted video streaming platform. Go backend + Next.js frontend in a single Docker container. +

🎬 KV-Tube

-## Quick Start +

+ Self-hosted video streaming platform
+ Go backend + Next.js frontend — single Docker container +

+ +

+ Quick Start • + Features • + Architecture • + Deployment • + Development +

+ +--- + +

🚀 Quick Start

```bash git clone https://github.com/vndangkhoa/kv-tube.git @@ -12,30 +33,70 @@ docker build -t kv-tube:latest . docker compose up -d ``` -- **Frontend:** http://localhost:5011 -- **API:** http://localhost:8981 +

+ Frontend: http://localhost:5011  •  + API: http://localhost:8981 +

-## Features +--- -- High-resolution video playback with HLS and quality selection -- Watch history, subscriptions, and search -- Background audio playback (mobile-friendly) -- Progressive Web App (installable) -- Region selection -- Light/dark theme, responsive design -- Infinite scrolling, skeleton loaders +

✨ Features

-## Architecture + + + + + + + + + + + + + + + + + + + + + + + + + +
🎞️Video Playback
HLS streaming with quality selection
📜Watch History
Track what you've watched
🔔Subscriptions
Follow YouTube channels
🔍Search
Find videos instantly
🎵Background Audio
Play with screen locked
📱PWA
Install as native app
🌍Region Selection
Tailor content by region
🌓Themes
Light & dark mode
+ +--- + +

🏗️ Architecture

+ +

+ + + + + + + +

Single unified Docker container running: -- **Backend:** Go (Gin framework) — API server on port 8080 -- **Frontend:** Next.js 16 (standalone) — SSR on port 3000 -- **Process Manager:** supervisord manages both processes -- **Storage:** SQLite for watch history and metadata -## Deployment +| Component | Tech | Port | Role | +|-----------|------|------|------| +| **Backend** | Go + Gin | `8080` | REST API, video processing, yt-dlp | +| **Frontend** | Next.js 16 | `3000` | SSR, PWA, UI | +| **Process Manager** | supervisord | — | Manages both processes | +| **Storage** | SQLite | — | Watch history & metadata | -### Docker Compose +--- + +

📦 Deployment

+ +

🐳 Docker Compose

```yaml services: @@ -51,23 +112,28 @@ services: - KVTUBE_DATA_DIR=/app/data - GIN_MODE=release - NODE_ENV=production + - CORS_ALLOWED_ORIGINS=http://localhost:3000,http://localhost:5011 restart: unless-stopped ``` -### Synology NAS (DSM 7.2+) +

🖥️ Synology NAS (DSM 7.2+)

-1. Create `/volume1/docker/kv-tube/data` -2. Upload `docker-compose.yml`, `Dockerfile`, `supervisord.conf` -3. Open **Container Manager** > **Project** > **Create** -4. Select path `/volume1/docker/kv-tube`, click **Done** +
    +
  1. Create /volume1/docker/kv-tube/data
  2. +
  3. Upload docker-compose.yml, Dockerfile, supervisord.conf
  4. +
  5. Open Container Manager > Project > Create
  6. +
  7. Select path /volume1/docker/kv-tube, click Done
  8. +
-### Multi-arch Build +

🛠️ Multi-arch Build

```bash docker buildx build --platform linux/amd64 -t kv-tube:latest --push . ``` -## Environment Variables +--- + +

⚙️ Environment Variables

| Variable | Default | Description | |----------|---------|-------------| @@ -77,7 +143,9 @@ docker buildx build --platform linux/amd64 -t kv-tube:latest --push . | `CORS_ALLOWED_ORIGINS` | — | Comma-separated allowed CORS origins | | `PORT` | `8080` | Backend API port | -## Development +--- + +

💻 Development

```bash # Frontend @@ -90,15 +158,23 @@ cd backend go run main.go ``` -## Updating +--- + +

🔄 Updating

```bash docker compose pull docker compose up -d ``` -Or enable auto-updates with [Watchtower](https://github.com/containrrr/watchtower). +Or enable auto-updates with Watchtower. -## License +--- -MIT License — see [LICENSE](LICENSE) for details. +

📄 License

+ +

+ License +

+ +MIT License — see LICENSE for details.