Add docker support
This commit is contained in:
@@ -13,6 +13,8 @@ A simple Flask proxy server that uses yt-dlp to fetch HLS streams and serves the
|
||||
|
||||
## Quick Start
|
||||
|
||||
### Option 1: Direct Python
|
||||
|
||||
```bash
|
||||
pip install -r requirements.txt
|
||||
python app.py
|
||||
@@ -20,6 +22,24 @@ python app.py
|
||||
|
||||
Visit http://localhost:5000 and enter a video URL.
|
||||
|
||||
### Option 2: Docker
|
||||
|
||||
```bash
|
||||
# Build and run
|
||||
docker-compose up -d
|
||||
|
||||
# Or pull from GitHub Container Registry (if available)
|
||||
docker pull ghcr.io/yourusername/yt-dlp-proxy:latest
|
||||
docker run -p 5000:5000 ghcr.io/yourusername/yt-dlp-proxy:latest
|
||||
```
|
||||
|
||||
### Option 3: Docker Build
|
||||
|
||||
```bash
|
||||
docker build -t yt-dlp-proxy .
|
||||
docker run -p 5000:5000 yt-dlp-proxy
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
| Variable | Default | Description |
|
||||
@@ -32,6 +52,30 @@ Visit http://localhost:5000 and enter a video URL.
|
||||
| ALLOWED_DOMAINS | youtube.com,youtu.be,pornhub.com,xvideos.com | Allowed video domains |
|
||||
| ALLOW_LOCAL | true | Allow localhost/127.0.0.1 URLs (for testing) |
|
||||
|
||||
### Docker Environment Variables
|
||||
|
||||
```bash
|
||||
docker run -e PORT=5000 -e LOG_LEVEL=INFO -p 5000:5000 yt-dlp-proxy
|
||||
```
|
||||
|
||||
### Docker Compose Example
|
||||
|
||||
```yaml
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
yt-dlp-proxy:
|
||||
image: yt-dlp-proxy
|
||||
ports:
|
||||
- "5000:5000"
|
||||
environment:
|
||||
- PORT=5000
|
||||
- LOG_LEVEL=INFO
|
||||
- CACHE_TTL=31536000
|
||||
- ALLOWED_DOMAINS=youtube.com,youtu.be,pornhub.com,xvideos.com
|
||||
restart: unless-stopped
|
||||
```
|
||||
|
||||
## Routes
|
||||
|
||||
- `/` - Home page with video URL input
|
||||
|
||||
Reference in New Issue
Block a user