DkMovie

A full-stack video streaming platform.

DkMovie is a full-stack video streaming platform. Built with performance and scalability in mind, it features adaptive bitrate streaming (HLS), multi-language support for audio and subtitles, and strict concurrency control.

🚀 Key Features

  • Adaptive Streaming (HLS): Automatically adjusts video quality (1080p, 720p, 480p) based on the user's bandwidth using FFmpeg transcoding.
  • Media Management: Support for movies and series (seasons & episodes).
  • Audio & Subtitles: Multi-track support with automatic extraction and separate management for different languages.
  • Concurrency Control: Limits the number of simultaneous active screens per user with heartbeat monitoring.
  • Secure Storage: Private object storage (Cloudflare R2/MinIO) with signed URLs for content protection.
  • Modern UI/UX: Responsive interface with dark/light mode support and an advanced custom video player.

🛠️ Tech Stack

Backend

Frontend

Infrastructure

  • Containerization: Docker & Docker Compose.
  • Reverse Proxy: Traefik (Production).
  • Object Store: Cloudflare R2 (Production) / MinIO (Local development).

⚡ Getting Started

This project is fully containerized. You only need Docker to run it locally.

Prerequisites

  • Docker installed and running.
  • Git (optional, to clone the repo).

Installation

Clone the repository

git clone https://github.com/ncontiero/dkmovie.git
cd dkmovie

Configure Environment Variables

Copy the example environment configuration folder to the active one.

cp -r .envs.example .envs

Note: The default credentials in .envs/.local/ are pre-configured for local development with Docker.

Build and Start

Run the project using the local docker-compose configuration.

docker compose -f docker-compose.local.yml up --build

This may take a few minutes on the first run as it builds the images and installs dependencies (including FFmpeg).

Access the Application

Post-Installation (Optional)

To create a superuser for the Django Admin:

docker compose -f docker-compose.local.yml run --rm django python manage.py createsuperuser

To run database migrations manually (usually handled automatically):

docker compose -f docker-compose.local.yml run --rm django python manage.py migrate

To compile messages (i18n support):

docker compose -f docker-compose.local.yml run --rm django python manage.py compilemessages

📦 Video Upload & Processing Flow

  1. Create a title (movie/series) via Django Admin.
  2. Upload a video file for the title.
  3. The system automatically triggers a Celery task.
  4. FFmpeg converts the video to HLS format (multiple resolutions) and extracts available audio/subtitle tracks.
  5. Files are uploaded to the private S3 bucket.
  6. Once completed, the video becomes available for streaming on the frontend.

📝 License

This project is licensed under the MIT License.